diff --git a/README.md b/README.md index 1564b2324..1555b78ad 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # CleverAgents Core -CleverAgents is the Python-first migration of the Plandex automation platform. It provides a unified `agents` CLI, embedded runtime, and service orchestration tools that mirror the original Go workflows while embracing modern Python tooling. +CleverAgents is a Python-first automation platform. It provides a unified `agents` CLI, embedded runtime, and service orchestration tools while embracing modern Python tooling. ## Highlights @@ -79,4 +79,4 @@ Set `CLEVERAGENTS_DEFAULT_PROVIDER` to pin the global provider (for example `exp - `agents tell` and `agents build` require `--actor ` unless a default actor is set; use `agents actor set-default ` to configure one. - Built-in actors (`/`) are immutable, custom actors must be named `local/`, and the default actor cannot be removed. Use `--unsafe` when adding/updating configs marked unsafe; runtime only warns when invoking unsafe actors. - `CLEVERAGENTS_TESTING_USE_MOCK_AI=true` forces the in-repo mock provider so Behave/Robot suites never hit external APIs. -- The full capability matrix (streaming, tool calls, JSON mode, etc.) plus every supported environment variable is documented in `docs/reference/providers.md` and `docs/reference/env_variables.yaml`. +- The full capability matrix (streaming, tool calls, JSON mode, etc.) is documented in `docs/reference/providers.md`. diff --git a/docs/architecture/decisions/ADR-002-asyncio-concurrency.md b/docs/architecture/decisions/ADR-002-asyncio-concurrency.md index bcf36d494..af5fdfb74 100644 --- a/docs/architecture/decisions/ADR-002-asyncio-concurrency.md +++ b/docs/architecture/decisions/ADR-002-asyncio-concurrency.md @@ -4,7 +4,7 @@ Accepted ## Context -The discovery phase identified 61 concurrent behaviors in the Plandex Go implementation, including: +The discovery phase identified 61 concurrent behaviors in the legacy Go implementation, including: - 33 retry/backoff patterns - 7 concurrency patterns using goroutines - 5 locking behaviors @@ -171,4 +171,4 @@ result = await asyncio.to_thread(cpu_intensive_function, *args) ## References - [Python asyncio documentation](https://docs.python.org/3/library/asyncio.html) - [Trio: Async concurrency for mere mortals](https://trio.readthedocs.io/) (design inspiration) -- [Go Concurrency Patterns](https://go.dev/blog/pipelines) (source patterns) \ No newline at end of file +- [Go Concurrency Patterns](https://go.dev/blog/pipelines) (source patterns) diff --git a/docs/architecture/decisions/ADR-006-environment-variables.md b/docs/architecture/decisions/ADR-006-environment-variables.md index e820e7239..d685b8ff8 100644 --- a/docs/architecture/decisions/ADR-006-environment-variables.md +++ b/docs/architecture/decisions/ADR-006-environment-variables.md @@ -4,7 +4,7 @@ Accepted ## Context -The discovery phase identified 66 environment variables that need management. CleverAgents is a standalone project (not a Plandex migration), so all application variables must use the `CLEVERAGENTS_` prefix. Provider-specific variables (OPENAI_API_KEY, ANTHROPIC_API_KEY, etc.) remain unchanged as they reference external services. +The discovery phase identified 66 environment variables that need management. CleverAgents is a standalone project, so all application variables must use the `CLEVERAGENTS_` prefix. Provider-specific variables (OPENAI_API_KEY, ANTHROPIC_API_KEY, etc.) remain unchanged as they reference external services. We need a strategy that: - Maintains clear namespace separation @@ -238,7 +238,7 @@ def generate_env_docs() -> str: - Easy testing with override utilities - Auto-generated documentation - Hierarchical configuration support -- No Plandex compatibility baggage +- No legacy compatibility baggage ### Negative - Verbose variable names (CLEVERAGENTS_ prefix) @@ -256,11 +256,9 @@ Based on the 66 variables discovered, here's the mapping: | Original Pattern | CleverAgents Pattern | |-----------------|---------------------| -| `PLANDEX_*` | `CLEVERAGENTS_*` | | `OPENAI_API_KEY` | `OPENAI_API_KEY` (unchanged) | | `ANTHROPIC_API_KEY` | `ANTHROPIC_API_KEY` (unchanged) | | `GOPATH` | Not needed (Python) | -| `PLANDEX_ENV` | `CLEVERAGENTS_DEBUG_ENABLED` | ## Usage Examples @@ -313,4 +311,3 @@ def test_with_custom_settings(): ## References - [Pydantic Settings Documentation](https://docs.pydantic.dev/latest/usage/pydantic_settings/) - [12-Factor App Config](https://12factor.net/config) -- Discovery artifact: `docs/reference/env_variables.yaml` \ No newline at end of file diff --git a/docs/architecture/decisions/ADR-008-provider-plugin-architecture.md b/docs/architecture/decisions/ADR-008-provider-plugin-architecture.md index 3dee2ef59..27c6d0a75 100644 --- a/docs/architecture/decisions/ADR-008-provider-plugin-architecture.md +++ b/docs/architecture/decisions/ADR-008-provider-plugin-architecture.md @@ -85,7 +85,7 @@ The concrete registry (`src/cleveragents/providers/registry.py:1-357`) and setti - **Mock isolation:** `CLEVERAGENTS_TESTING_USE_MOCK_AI` remains the only bypass inside `application/container.py`, keeping mocks out of production code per the implementation plan. - **Actor registry boundaries:** The registry persists canonical config blobs/hashes/graph descriptors, seeds immutable built-in actors named `/` from settings defaults, enforces `local/` for custom actors, blocks removal of built-ins or the default actor, and requires `--unsafe` confirmation when an actor config is marked unsafe; CLI help/docs mirror these guards and must avoid `--provider/--model` references. Actor config files must stay in the v2 format (no alternative schemas) and remain the source of provider/model/options/graph_descriptor truth. -These details are mirrored in `docs/reference/providers.md` and `docs/reference/env_variables.yaml` so the ADR now points at the actual runtime behavior. +These details are mirrored in `docs/reference/providers.md` so the ADR now points at the actual runtime behavior. ### Provider Implementations @@ -183,4 +183,4 @@ class ModelCatalog: ## References - Strategy Pattern - Plugin Architecture -- OpenAI API Documentation \ No newline at end of file +- OpenAI API Documentation diff --git a/docs/implementation_plan_updates.md b/docs/implementation_plan_updates.md deleted file mode 100644 index af810495c..000000000 --- a/docs/implementation_plan_updates.md +++ /dev/null @@ -1,75 +0,0 @@ -# Implementation Plan Updates - Phase 0 Review - -## Changes Made (2025-11-04) - -### 1. Phase 0 Completion Assessment -- Reviewed all Phase 0 tasks and confirmed completion of core discovery objectives -- Verified all 8 discovery extractors are functional and producing usable artifacts -- Confirmed 92% test coverage exceeds the 85% requirement -- All tests passing (13 Behave features, 76 scenarios, 419 steps) - -### 2. Deferred Tasks Properly Moved -The following tasks were removed from Phase 0 and added to their appropriate target phases: - -#### Moved to Phase 2 (Runtime Modes): -- Identify handler dependencies (DB helpers, queue usage, external services) -- Trace middleware usage (rate limiting, auth, logging) -- Capture latency/timeout settings from Go handlers -- Define authentication strategies and rate limiting for endpoints -- Assert authentication and streaming metadata alignment - -These tasks are now integrated into the Phase 2 server implementation checklist items. - -#### Moved to Phase 3 (Persistence Layer): -- Ensure round-trip serialization/deserialization with Python dataclasses - -This task is now part of the Phase 3 schema validation scenarios. - -#### Moved to Phase 5 (Command Parity): -- Diff CLI inventory against extracted Go commands for parity -- Document disputed or ambiguous command behaviors -- Verify CLI help text matches intended Python wording - -These tasks are now integrated into the Phase 5 CLI command implementation checklist. - -#### Removed (Not Applicable): -- Capture compatibility risks - Removed as CleverAgents is a standalone project with no backward compatibility requirements - -### 3. Enhanced Future Phases -Based on Phase 0 discoveries, the following enhancements were added: - -#### Phase 1 (Architecture Definition): -- Added 10 specific ADRs needed based on discovery findings -- Refined package structure to accommodate 67 commands, 122 structs, 62 workflows -- Added specific module paths for each major component - -#### Phase 2 (Runtime Modes): -- Added asyncio-first design requirements -- Integrated handling for 61 concurrent behaviors -- Added support for 33 retry patterns using tenacity -- Specified 66 CLEVERAGENTS_* environment variables management -- Enhanced server implementation with discovery findings - -#### Phase 3 (Persistence): -- Added specifics for converting 122 Go structs to SQLAlchemy models -- Defined repository pattern for discovered workflows -- Added async SQLAlchemy 2.0 requirement - -#### Phase 11 (Cleanup): -- Added verification requirements for complete independence from Plandex -- Specified validation criteria for standalone operation - -### 4. Documentation Updates -- Created comprehensive Phase 0 completion report -- Updated Phase 0 review section with detailed statistics and findings -- Enhanced Notes sections for Phases 1, 2, 3, and 11 with discovery insights - -## Result -The implementation plan now accurately reflects: -- Phase 0 is complete with all core tasks finished -- Deferred tasks are properly placed in their target phases -- Future phases are enhanced with specific requirements from discovery -- CleverAgents will be a fully independent application with no Plandex dependencies - -## Next Steps -Ready to proceed to Phase 1: Architecture Definition with comprehensive understanding of all components needed for the CleverAgents implementation. \ No newline at end of file diff --git a/docs/index.md b/docs/index.md index 73cbe1b67..0c271717a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,6 +1,6 @@ # CleverAgents Core Documentation -CleverAgents is the Python implementation of the Plandex automation platform. This documentation tracks the migration effort and provides guidance for contributors porting the Go functionality to Python. +CleverAgents is a standalone Python automation platform. This documentation covers developer workflows, CLI usage, and architecture decisions. ## Current Deliverables @@ -20,16 +20,12 @@ nox -s unit_tests nox -s integration_tests ``` -## Migration Notes +## Contributor Notes -- Reference the Go sources under `plandex/` for feature parity—never modify that directory. -- All CLI branding should use CleverAgents terminology; retain `plandex` only as a compatibility alias. - Document discoveries and open questions directly in `implementation_plan.md` under the appropriate phase. ## Next Steps -- Expand discovery tooling for CLI, server routes, and shared contracts (Phase 0 checklist). -- Add Robot suites validating route mapping and configuration parity. -- Create ADRs defining CleverAgents architecture (Phase 1). +- Follow the Implementation Checklist in `implementation_plan.md` for current priorities. For detailed progress, follow the living checklist in `implementation_plan.md`. diff --git a/docs/phase0_completion_report.md b/docs/phase0_completion_report.md deleted file mode 100644 index b9695b625..000000000 --- a/docs/phase0_completion_report.md +++ /dev/null @@ -1,111 +0,0 @@ -# Phase 0 Completion Report - -## Executive Summary - -Phase 0 of the CleverAgents Python implementation has been successfully completed. All discovery and requirements elaboration tasks have been executed, producing comprehensive documentation and artifacts that will guide the remaining phases of development. - -## Completion Status - -✅ **PHASE 0 COMPLETE** - All core objectives achieved - -### Deliverables Summary - -| Component | Status | Output | -|-----------|--------|--------| -| CLI Inventory | ✅ Complete | 67 commands extracted | -| Server Endpoints | ✅ Complete | 80 endpoints documented | -| Data Contracts | ✅ Complete | 122 structs, 25 enums converted | -| Shell Assets | ✅ Complete | 16 scripts cataloged | -| Environment Variables | ✅ Complete | 66 variables mapped | -| Implicit Behaviors | ✅ Complete | 61 behaviors identified | -| Workflow Parity | ✅ Complete | 62 workflows mapped | -| Cloud Features | ✅ Complete | 38 features identified | -| Test Coverage | ✅ Complete | 92% (exceeds 85% requirement) | - -## Key Architectural Decisions - -Based on the Phase 0 discovery, the following critical decisions have been made: - -1. **Standalone Project**: CleverAgents is a new project, NOT a Plandex migration -2. **Environment Variables**: All use CLEVERAGENTS_* prefix (except provider APIs) -3. **Concurrency Model**: Asyncio for all I/O operations -4. **Validation**: Pydantic for runtime data validation -5. **Retry Logic**: Tenacity library for resilience patterns -6. **Cloud Features**: Remove or replace with self-hosted alternatives - -## Deferred Tasks - -Several documentation and validation tasks have been strategically deferred to more appropriate phases: - -### To Phase 2 (Runtime) -- Handler dependency analysis -- Middleware requirements -- Timeout configuration -- Authentication strategies - -### To Phase 3 (Persistence) -- Round-trip serialization testing - -### To Phase 5 (Commands) -- CLI documentation validation -- Command behavior resolution -- Help text verification - -## Artifact Locations - -All discovery artifacts are stored in `docs/reference/`: - -``` -docs/reference/ -├── cli_inventory.{yaml,json} # 67 CLI commands -├── server_endpoints.{yaml,json} # 80 server endpoints -├── server_api.yaml # OpenAPI specification -├── contracts/ # Data structures -│ ├── data_contracts.{yaml,json} # 122 structs, 25 enums -│ ├── stubs/ # Python dataclass stubs -│ └── fixtures/ # Example payloads -├── shell_assets.{yaml,json} # 16 shell scripts -├── shell_wrappers/ # Python replacements -├── env_*.{yaml,json,txt} # 66 environment variables -├── behaviors/ # Implicit behaviors -│ └── implicit_behaviors.* # 61 runtime patterns -├── workflows/ # Workflow mapping -│ └── workflow_parity.* # 62 workflows -└── cloud/ # Cloud features - └── cloud_features.* # 38 features -``` - -## Test Results - -All tests passing with excellent coverage: - -- **13 Behave feature files**: Comprehensive unit testing -- **7 Robot Framework suites**: Integration testing -- **92% code coverage**: Exceeds 85% requirement -- **CI Pipeline**: All checks green - -## Ready for Phase 1 - -The project is now ready to proceed to Phase 1: Architecture Definition with: - -1. Complete understanding of the Plandex codebase -2. Comprehensive documentation of all components -3. Clear migration path for each feature -4. Solid test foundation -5. Well-defined architectural constraints - -## Next Steps - -Phase 1 will focus on: - -1. Creating Architecture Decision Records (ADRs) -2. Defining Python package structure -3. Establishing coding standards -4. Setting up build tooling - -All Phase 0 discoveries have been integrated into the implementation plan with specific updates for each future phase. - ---- - -*Report Generated: 2025-11-04* -*CleverAgents Core - Building the future of AI-assisted development* \ No newline at end of file diff --git a/docs/reference/behaviors/implicit_behaviors.json b/docs/reference/behaviors/implicit_behaviors.json deleted file mode 100644 index 00a0a04b6..000000000 --- a/docs/reference/behaviors/implicit_behaviors.json +++ /dev/null @@ -1,2783 +0,0 @@ -{ - "behaviors": [ - { - "name": "Auto-Context: Auto-load context configuration", - "category": "auto-context", - "description": "Automatic context loading based on auto-load context configuration", - "locations": [ - "app/cli/api/methods.go:2386", - "app/cli/cmd/ls.go:96", - "app/cli/cmd/new.go:104", - "app/cli/cmd/new.go:128", - "app/cli/cmd/plan_exec_helpers.go:187", - "app/cli/cmd/plan_start_helpers.go:218", - "app/cli/cmd/repl.go:833", - "app/cli/cmd/set_config.go:333", - "app/cli/cmd/set_config.go:356", - "app/cli/stream_tui/model.go:84" - ], - "triggers": [ - "CLI command execution", - "@ symbol in input" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use Python decorators for auto-loading", - "Consider asyncio for concurrent context loads" - ] - }, - { - "name": "Auto-Context: At-symbol context references", - "category": "auto-context", - "description": "Automatic context loading based on at-symbol context references", - "locations": [ - "app/cli/auth/account.go:189", - "app/cli/auth/trial.go:38", - "app/cli/auth/trial.go:86" - ], - "triggers": [ - "CLI command execution", - "@ symbol in input" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use Python decorators for auto-loading", - "Consider asyncio for concurrent context loads" - ] - }, - { - "name": "Locking: Explicit lock acquisition", - "category": "locking", - "description": "Resource locking via explicit lock acquisition", - "locations": [ - "app/server/db/context_helpers_get.go:46", - "app/server/db/context_helpers_get.go:47", - "app/server/db/context_helpers_load.go:337", - "app/server/db/context_helpers_load.go:342", - "app/server/db/context_helpers_update.go:163", - "app/server/db/context_helpers_update.go:164", - "app/server/db/context_helpers_update.go:316", - "app/server/db/context_helpers_update.go:325", - "app/server/db/locks.go:381", - "app/server/db/locks.go:383", - "app/server/db/locks.go:516", - "app/server/db/locks.go:518", - "app/server/db/locks.go:662", - "app/server/db/locks.go:664", - "app/server/db/queue.go:43", - "app/server/db/queue.go:44", - "app/server/db/queue.go:72", - "app/server/db/queue.go:90", - "app/server/db/queue.go:96", - "app/server/db/queue.go:97", - "app/server/db/queue.go:163", - "app/server/db/queue.go:165", - "app/server/db/result_helpers.go:1070", - "app/server/db/result_helpers.go:1072" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Locking: Lock release", - "category": "locking", - "description": "Resource locking via lock release", - "locations": [ - "app/server/db/context_helpers_get.go:47", - "app/server/db/context_helpers_load.go:342", - "app/server/db/context_helpers_update.go:164", - "app/server/db/context_helpers_update.go:325", - "app/server/db/locks.go:383", - "app/server/db/locks.go:518", - "app/server/db/locks.go:664", - "app/server/db/queue.go:44", - "app/server/db/queue.go:90", - "app/server/db/queue.go:97", - "app/server/db/queue.go:165", - "app/server/db/result_helpers.go:1072" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Locking: Mutex usage", - "category": "locking", - "description": "Resource locking via mutex usage", - "locations": [ - "app/server/db/context_helpers_get.go:31", - "app/server/db/context_helpers_load.go:288", - "app/server/db/context_helpers_update.go:137", - "app/server/db/locks.go:39", - "app/server/db/queue.go:33", - "app/server/db/queue.go:39", - "app/server/db/result_helpers.go:1042" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Locking: File-based locking", - "category": "locking", - "description": "Resource locking via file-based locking", - "locations": [ - "app/server/db/git.go:404", - "app/server/db/git.go:416", - "app/server/db/git.go:430", - "app/server/db/git.go:557", - "app/server/db/git.go:558", - "app/server/db/git.go:571", - "app/server/db/git.go:573", - "app/server/db/git.go:575", - "app/server/db/git.go:582", - "app/server/db/git.go:589", - "app/server/db/git.go:591", - "app/server/db/git.go:593", - "app/server/db/git.go:604", - "app/server/db/git.go:605", - "app/server/db/git.go:619", - "app/server/db/git.go:620", - "app/server/db/git.go:624", - "app/server/db/git.go:673", - "app/server/db/locks.go:461" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Locking: Deferred unlock patterns", - "category": "locking", - "description": "Resource locking via deferred unlock patterns", - "locations": [ - "app/server/db/context_helpers_get.go:47", - "app/server/db/context_helpers_update.go:164", - "app/server/db/queue.go:44", - "app/server/db/queue.go:97" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Retry: Manual retry loops", - "category": "retry", - "description": "Retry logic using manual retry loops", - "locations": [ - "app/cli/api/clients.go:82" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Backoff patterns", - "category": "retry", - "description": "Retry logic using backoff patterns", - "locations": [ - "app/cli/api/clients.go:108", - "app/cli/api/clients.go:109", - "app/cli/api/clients.go:110", - "app/cli/api/clients.go:111", - "app/cli/api/clients.go:113" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Max retry configuration", - "category": "retry", - "description": "Retry logic using max retry configuration", - "locations": [ - "app/cli/api/clients.go:68", - "app/cli/api/clients.go:82", - "app/cli/api/clients.go:104", - "app/cli/api/clients.go:129" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/auth/trial.go:34", - "app/cli/auth/trial.go:82" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/cmd/cd.go:113" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Manual retry loops", - "category": "retry", - "description": "Retry logic using manual retry loops", - "locations": [ - "app/cli/cmd/debug.go:78" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/cmd/tell.go:252" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/plan_exec/tell.go:239" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/stream_tui/update.go:569" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/term/spinner.go:66", - "app/cli/term/spinner.go:72" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Manual retry loops", - "category": "retry", - "description": "Retry logic using manual retry loops", - "locations": [ - "app/server/db/git.go:658" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/db/git.go:598" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Backoff patterns", - "category": "retry", - "description": "Retry logic using backoff patterns", - "locations": [ - "app/server/db/git.go:660" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Retry delay configuration", - "category": "retry", - "description": "Retry logic using retry delay configuration", - "locations": [ - "app/server/db/git.go:21", - "app/server/db/git.go:660" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Backoff patterns", - "category": "retry", - "description": "Retry logic using backoff patterns", - "locations": [ - "app/server/db/locks.go:31", - "app/server/db/locks.go:32", - "app/server/db/locks.go:34", - "app/server/db/locks.go:163", - "app/server/db/locks.go:185", - "app/server/db/locks.go:287", - "app/server/db/locks.go:344", - "app/server/db/locks.go:345", - "app/server/db/locks.go:364", - "app/server/db/locks.go:564", - "app/server/db/locks.go:577", - "app/server/db/locks.go:579", - "app/server/db/locks.go:582", - "app/server/db/locks.go:604" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Retry delay configuration", - "category": "retry", - "description": "Retry logic using retry delay configuration", - "locations": [ - "app/server/db/locks.go:30", - "app/server/db/locks.go:36", - "app/server/db/locks.go:576", - "app/server/db/locks.go:577", - "app/server/db/locks.go:608" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/handlers/plans_changes.go:39", - "app/server/handlers/plans_changes.go:143" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/handlers/plans_exec.go:296" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/handlers/stream_helper.go:53", - "app/server/handlers/stream_helper.go:69", - "app/server/handlers/stream_helper.go:71" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Max retry configuration", - "category": "retry", - "description": "Retry logic using max retry configuration", - "locations": [ - "app/server/model/client_stream.go:277", - "app/server/model/client_stream.go:279", - "app/server/model/client_stream.go:291", - "app/server/model/client_stream.go:316", - "app/server/model/client_stream.go:317" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Retry delay configuration", - "category": "retry", - "description": "Retry logic using retry delay configuration", - "locations": [ - "app/server/model/client_stream.go:321", - "app/server/model/client_stream.go:324", - "app/server/model/client_stream.go:327", - "app/server/model/client_stream.go:330", - "app/server/model/client_stream.go:331" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/activate.go:29" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/build_exec.go:350" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Backoff patterns", - "category": "retry", - "description": "Retry logic using backoff patterns", - "locations": [ - "app/server/model/plan/build_state.go:14" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/build_structured_edits.go:190" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/state.go:83" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/tell_exec.go:132" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Max retry configuration", - "category": "retry", - "description": "Retry logic using max retry configuration", - "locations": [ - "app/server/model/plan/tell_stream_error.go:59", - "app/server/model/plan/tell_stream_error.go:61", - "app/server/model/plan/tell_stream_error.go:97", - "app/server/model/plan/tell_stream_error.go:127", - "app/server/model/plan/tell_stream_error.go:244" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Retry delay configuration", - "category": "retry", - "description": "Retry logic using retry delay configuration", - "locations": [ - "app/server/model/plan/tell_stream_error.go:111", - "app/server/model/plan/tell_stream_error.go:114", - "app/server/model/plan/tell_stream_error.go:117", - "app/server/model/plan/tell_stream_error.go:127", - "app/server/model/plan/tell_stream_error.go:128" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/tell_stream_finish.go:52", - "app/server/model/plan/tell_stream_finish.go:54", - "app/server/model/plan/tell_stream_finish.go:233" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/tell_stream_processor.go:663" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Max retry configuration", - "category": "retry", - "description": "Retry logic using max retry configuration", - "locations": [ - "app/server/syntax/file_map/examples/go_example.go:43" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/types/active_plan.go:271", - "app/server/types/active_plan.go:285", - "app/server/types/active_plan.go:307" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Validation: Validation functions", - "category": "validation", - "description": "Input validation via validation functions", - "locations": [ - "app/cli/cmd/plan_exec_helpers.go:131", - "app/cli/cmd/plan_exec_helpers.go:218", - "app/cli/schema/schemas.go:36", - "app/cli/schema/schemas.go:37", - "app/cli/schema/schemas.go:40", - "app/cli/schema/schemas.go:41", - "app/cli/schema/schemas.go:44", - "app/server/db/auth_helpers.go:33", - "app/server/db/auth_helpers.go:80", - "app/server/db/auth_helpers.go:81" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: Sanitization functions", - "category": "validation", - "description": "Input validation via sanitization functions", - "locations": [ - "app/cli/url/url.go:70", - "app/cli/url/url.go:76", - "app/cli/url/url.go:77", - "app/cli/url/url.go:78", - "app/cli/url/url.go:79", - "app/cli/url/url.go:80", - "app/cli/url/url.go:81", - "app/cli/url/url.go:82", - "app/cli/url/url.go:83", - "app/cli/url/url.go:84" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: Empty string checks", - "category": "validation", - "description": "Input validation via empty string checks", - "locations": [ - "app/cli/api/clients.go:26", - "app/cli/api/methods.go:1259", - "app/cli/api/methods.go:1291", - "app/cli/api/methods.go:1662", - "app/cli/auth/auth.go:58", - "app/cli/auth/auth.go:73", - "app/cli/auth/auth.go:104", - "app/cli/cmd/apply.go:45", - "app/cli/cmd/archive.go:54", - "app/cli/cmd/branches.go:33" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: String trimming", - "category": "validation", - "description": "Input validation via string trimming", - "locations": [ - "app/cli/upgrade.go:60", - "app/cli/api/errors.go:20", - "app/cli/api/errors.go:30", - "app/cli/cmd/archive.go:36", - "app/cli/cmd/cd.go:37", - "app/cli/cmd/checkout.go:50", - "app/cli/cmd/delete_branch.go:40", - "app/cli/cmd/delete_plan.go:91", - "app/cli/cmd/repl.go:316", - "app/cli/cmd/repl.go:319" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: Regex validation", - "category": "validation", - "description": "Input validation via regex validation", - "locations": [ - "app/cli/cmd/convo.go:178", - "app/cli/cmd/repl.go:488", - "app/cli/cmd/rewind.go:91", - "app/cli/cmd/rewind.go:503", - "app/cli/url/url.go:72", - "app/server/model/model_error.go:25", - "app/server/model/model_error.go:28", - "app/server/model/model_error.go:34", - "app/server/model/plan/tell_context.go:368", - "app/server/model/plan/tell_stream_processor.go:22" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: Validation errors", - "category": "validation", - "description": "Input validation via validation errors", - "locations": [ - "app/server/db/auth_helpers.go:38", - "app/server/db/auth_helpers.go:51", - "app/server/model/prompts/explanation_format.go:456", - "app/server/model/prompts/explanation_format.go:482", - "app/server/model/prompts/explanation_format.go:680", - "app/server/model/prompts/explanation_format.go:709" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Concurrency: Anonymous goroutines", - "category": "concurrency", - "description": "Concurrent execution via anonymous goroutines", - "locations": [ - "app/cli/api/stream.go:24", - "app/cli/cmd/connect.go:52", - "app/cli/cmd/debug.go:109", - "app/cli/cmd/debug.go:161", - "app/cli/cmd/diffs.go:119", - "app/cli/cmd/models.go:103", - "app/cli/cmd/models.go:113", - "app/cli/cmd/new.go:50", - "app/cli/cmd/new.go:60", - "app/cli/cmd/plans.go:61" - ], - "triggers": [], - "timing": null, - "concurrency": "Go anonymous goroutines", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Named goroutine calls", - "category": "concurrency", - "description": "Concurrent execution via named goroutine calls", - "locations": [ - "app/cli/api/stream.go:24", - "app/cli/cmd/connect.go:52", - "app/cli/cmd/debug.go:109", - "app/cli/cmd/debug.go:161", - "app/cli/cmd/diffs.go:119", - "app/cli/cmd/models.go:103", - "app/cli/cmd/models.go:113", - "app/cli/cmd/new.go:50", - "app/cli/cmd/new.go:60", - "app/cli/cmd/plans.go:61" - ], - "triggers": [], - "timing": null, - "concurrency": "Go named goroutine calls", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Channel declarations", - "category": "concurrency", - "description": "Concurrent execution via channel declarations", - "locations": [ - "app/cli/cmd/browser.go:168", - "app/cli/cmd/browser.go:171", - "app/cli/cmd/debug.go:105", - "app/cli/cmd/models.go:101", - "app/cli/cmd/new.go:45", - "app/cli/cmd/plans.go:56", - "app/cli/cmd/revoke.go:35", - "app/cli/cmd/set_model.go:159", - "app/cli/cmd/tell.go:224", - "app/cli/cmd/users.go:33" - ], - "triggers": [], - "timing": null, - "concurrency": "Go channel declarations", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Select statements", - "category": "concurrency", - "description": "Concurrent execution via select statements", - "locations": [ - "app/cli/api/stream.go:26", - "app/cli/cmd/browser.go:225", - "app/cli/cmd/connect.go:66", - "app/cli/cmd/debug.go:112", - "app/cli/cmd/debug.go:140", - "app/cli/cmd/reject.go:127", - "app/cli/fs/projects.go:73", - "app/cli/term/select.go:13", - "app/server/db/convo_helpers.go:68", - "app/server/db/locks.go:80" - ], - "triggers": [], - "timing": null, - "concurrency": "Go select statements", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Channel receive", - "category": "concurrency", - "description": "Concurrent execution via channel receive", - "locations": [ - "app/cli/api/stream.go:27", - "app/cli/cmd/browser.go:226", - "app/cli/cmd/browser.go:229", - "app/cli/cmd/browser.go:232", - "app/cli/cmd/debug.go:113", - "app/cli/cmd/debug.go:141", - "app/cli/cmd/debug.go:147", - "app/cli/cmd/debug.go:152", - "app/cli/cmd/models.go:124", - "app/cli/cmd/new.go:71" - ], - "triggers": [], - "timing": null, - "concurrency": "Go channel receive", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Channel send", - "category": "concurrency", - "description": "Concurrent execution via channel send", - "locations": [ - "app/cli/api/stream.go:27", - "app/cli/cmd/browser.go:194", - "app/cli/cmd/browser.go:202", - "app/cli/cmd/browser.go:226", - "app/cli/cmd/browser.go:229", - "app/cli/cmd/browser.go:232", - "app/cli/cmd/debug.go:141", - "app/cli/cmd/debug.go:147", - "app/cli/cmd/debug.go:152", - "app/cli/cmd/models.go:107" - ], - "triggers": [], - "timing": null, - "concurrency": "Go channel send", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: WaitGroup usage", - "category": "concurrency", - "description": "Concurrent execution via waitgroup usage", - "locations": [ - "app/cli/cmd/debug.go:103", - "app/cli/stream_tui/run.go:18", - "app/server/db/queue.go:227", - "app/server/handlers/file_maps_queue.go:84", - "app/server/syntax/file_map/examples/go_example.go:153" - ], - "triggers": [], - "timing": null, - "concurrency": "Go waitgroup usage", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Streaming: Stream operations", - "category": "streaming", - "description": "Real-time data streaming via stream operations", - "locations": [ - "app/cli/cmd/connect.go:45", - "app/cli/plan_exec/build.go:56", - "app/cli/plan_exec/tell.go:151", - "app/server/db/stream_helpers.go:38", - "app/server/db/stream_helpers.go:39", - "app/server/db/stream_helpers.go:56", - "app/server/db/stream_helpers.go:58", - "app/server/db/stream_helpers.go:63", - "app/server/db/stream_helpers.go:111", - "app/server/db/stream_helpers.go:112" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Streaming: Server-sent events", - "category": "streaming", - "description": "Real-time data streaming via server-sent events", - "locations": [ - "app/cli/api/stream.go:16", - "app/cli/cmd/browser.go:89", - "app/cli/cmd/debug.go:123", - "app/cli/cmd/plan_exec_helpers.go:113", - "app/cli/cmd/plan_exec_helpers.go:118", - "app/cli/cmd/rewind.go:27", - "app/cli/cmd/rewind.go:28", - "app/cli/cmd/rewind.go:29", - "app/cli/cmd/rewind.go:48", - "app/cli/cmd/rewind.go:49" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Streaming: Stream copying", - "category": "streaming", - "description": "Real-time data streaming via stream copying", - "locations": [ - "app/cli/upgrade.go:118", - "app/server/handlers/proxy_helper.go:102" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Streaming: Buffered I/O", - "category": "streaming", - "description": "Real-time data streaming via buffered i/o", - "locations": [ - "app/cli/api/stream.go:20", - "app/cli/api/stream.go:72", - "app/cli/cmd/debug.go:160", - "app/cli/cmd/tell.go:123", - "app/server/diff/diff.go:74", - "app/server/model/client.go:91", - "app/server/model/client.go:386" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Streaming: Stream flushing", - "category": "streaming", - "description": "Real-time data streaming via stream flushing", - "locations": [ - "app/server/handlers/stream_helper.go:122" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Telemetry: Metrics collection", - "category": "telemetry", - "description": "Usage tracking via metrics collection", - "locations": [ - "app/server/syntax/structured_edits_test.go:123", - "app/server/syntax/structured_edits_test.go:150" - ], - "triggers": [ - "Command execution", - "Feature usage" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Make telemetry opt-in by default", - "Use structured logging for metrics", - "Consider OpenTelemetry for standards", - "Respect privacy settings strictly" - ] - }, - { - "name": "Telemetry: Tracking functions", - "category": "telemetry", - "description": "Usage tracking via tracking functions", - "locations": [ - "app/cli/fs/paths.go:91", - "app/cli/fs/paths.go:130", - "app/cli/fs/paths.go:138", - "app/cli/fs/paths.go:180", - "app/server/db/git.go:372", - "app/server/db/git.go:373", - "app/server/db/git.go:376", - "app/server/db/git.go:378", - "app/server/db/git.go:689", - "app/server/types/message.go:265" - ], - "triggers": [ - "Command execution", - "Feature usage" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Make telemetry opt-in by default", - "Use structured logging for metrics", - "Consider OpenTelemetry for standards", - "Respect privacy settings strictly" - ] - }, - { - "name": "Telemetry: Usage tracking", - "category": "telemetry", - "description": "Usage tracking via usage tracking", - "locations": [ - "app/server/model/model_request.go:204", - "app/server/model/model_request.go:205", - "app/server/model/model_request.go:207", - "app/server/model/model_request.go:208", - "app/server/model/summarize.go:88", - "app/server/model/plan/tell_stream_usage.go:23", - "app/server/model/plan/tell_stream_usage.go:24", - "app/server/model/plan/tell_stream_usage.go:44", - "app/server/model/plan/tell_stream_usage.go:45" - ], - "triggers": [ - "Command execution", - "Feature usage" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Make telemetry opt-in by default", - "Use structured logging for metrics", - "Consider OpenTelemetry for standards", - "Respect privacy settings strictly" - ] - } - ], - "by_category": { - "auto-context": [ - { - "name": "Auto-Context: Auto-load context configuration", - "category": "auto-context", - "description": "Automatic context loading based on auto-load context configuration", - "locations": [ - "app/cli/api/methods.go:2386", - "app/cli/cmd/ls.go:96", - "app/cli/cmd/new.go:104", - "app/cli/cmd/new.go:128", - "app/cli/cmd/plan_exec_helpers.go:187", - "app/cli/cmd/plan_start_helpers.go:218", - "app/cli/cmd/repl.go:833", - "app/cli/cmd/set_config.go:333", - "app/cli/cmd/set_config.go:356", - "app/cli/stream_tui/model.go:84" - ], - "triggers": [ - "CLI command execution", - "@ symbol in input" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use Python decorators for auto-loading", - "Consider asyncio for concurrent context loads" - ] - }, - { - "name": "Auto-Context: At-symbol context references", - "category": "auto-context", - "description": "Automatic context loading based on at-symbol context references", - "locations": [ - "app/cli/auth/account.go:189", - "app/cli/auth/trial.go:38", - "app/cli/auth/trial.go:86" - ], - "triggers": [ - "CLI command execution", - "@ symbol in input" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use Python decorators for auto-loading", - "Consider asyncio for concurrent context loads" - ] - } - ], - "locking": [ - { - "name": "Locking: Explicit lock acquisition", - "category": "locking", - "description": "Resource locking via explicit lock acquisition", - "locations": [ - "app/server/db/context_helpers_get.go:46", - "app/server/db/context_helpers_get.go:47", - "app/server/db/context_helpers_load.go:337", - "app/server/db/context_helpers_load.go:342", - "app/server/db/context_helpers_update.go:163", - "app/server/db/context_helpers_update.go:164", - "app/server/db/context_helpers_update.go:316", - "app/server/db/context_helpers_update.go:325", - "app/server/db/locks.go:381", - "app/server/db/locks.go:383", - "app/server/db/locks.go:516", - "app/server/db/locks.go:518", - "app/server/db/locks.go:662", - "app/server/db/locks.go:664", - "app/server/db/queue.go:43", - "app/server/db/queue.go:44", - "app/server/db/queue.go:72", - "app/server/db/queue.go:90", - "app/server/db/queue.go:96", - "app/server/db/queue.go:97", - "app/server/db/queue.go:163", - "app/server/db/queue.go:165", - "app/server/db/result_helpers.go:1070", - "app/server/db/result_helpers.go:1072" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Locking: Lock release", - "category": "locking", - "description": "Resource locking via lock release", - "locations": [ - "app/server/db/context_helpers_get.go:47", - "app/server/db/context_helpers_load.go:342", - "app/server/db/context_helpers_update.go:164", - "app/server/db/context_helpers_update.go:325", - "app/server/db/locks.go:383", - "app/server/db/locks.go:518", - "app/server/db/locks.go:664", - "app/server/db/queue.go:44", - "app/server/db/queue.go:90", - "app/server/db/queue.go:97", - "app/server/db/queue.go:165", - "app/server/db/result_helpers.go:1072" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Locking: Mutex usage", - "category": "locking", - "description": "Resource locking via mutex usage", - "locations": [ - "app/server/db/context_helpers_get.go:31", - "app/server/db/context_helpers_load.go:288", - "app/server/db/context_helpers_update.go:137", - "app/server/db/locks.go:39", - "app/server/db/queue.go:33", - "app/server/db/queue.go:39", - "app/server/db/result_helpers.go:1042" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Locking: File-based locking", - "category": "locking", - "description": "Resource locking via file-based locking", - "locations": [ - "app/server/db/git.go:404", - "app/server/db/git.go:416", - "app/server/db/git.go:430", - "app/server/db/git.go:557", - "app/server/db/git.go:558", - "app/server/db/git.go:571", - "app/server/db/git.go:573", - "app/server/db/git.go:575", - "app/server/db/git.go:582", - "app/server/db/git.go:589", - "app/server/db/git.go:591", - "app/server/db/git.go:593", - "app/server/db/git.go:604", - "app/server/db/git.go:605", - "app/server/db/git.go:619", - "app/server/db/git.go:620", - "app/server/db/git.go:624", - "app/server/db/git.go:673", - "app/server/db/locks.go:461" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - }, - { - "name": "Locking: Deferred unlock patterns", - "category": "locking", - "description": "Resource locking via deferred unlock patterns", - "locations": [ - "app/server/db/context_helpers_get.go:47", - "app/server/db/context_helpers_update.go:164", - "app/server/db/queue.go:44", - "app/server/db/queue.go:97" - ], - "triggers": [], - "timing": null, - "concurrency": "Go mutexes/file locks", - "failure_handling": "Deferred unlock ensures cleanup", - "python_considerations": [ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup" - ] - } - ], - "retry": [ - { - "name": "Retry: Manual retry loops", - "category": "retry", - "description": "Retry logic using manual retry loops", - "locations": [ - "app/cli/api/clients.go:82" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Backoff patterns", - "category": "retry", - "description": "Retry logic using backoff patterns", - "locations": [ - "app/cli/api/clients.go:108", - "app/cli/api/clients.go:109", - "app/cli/api/clients.go:110", - "app/cli/api/clients.go:111", - "app/cli/api/clients.go:113" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Max retry configuration", - "category": "retry", - "description": "Retry logic using max retry configuration", - "locations": [ - "app/cli/api/clients.go:68", - "app/cli/api/clients.go:82", - "app/cli/api/clients.go:104", - "app/cli/api/clients.go:129" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/auth/trial.go:34", - "app/cli/auth/trial.go:82" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/cmd/cd.go:113" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Manual retry loops", - "category": "retry", - "description": "Retry logic using manual retry loops", - "locations": [ - "app/cli/cmd/debug.go:78" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/cmd/tell.go:252" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/plan_exec/tell.go:239" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/stream_tui/update.go:569" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/cli/term/spinner.go:66", - "app/cli/term/spinner.go:72" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Manual retry loops", - "category": "retry", - "description": "Retry logic using manual retry loops", - "locations": [ - "app/server/db/git.go:658" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/db/git.go:598" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Backoff patterns", - "category": "retry", - "description": "Retry logic using backoff patterns", - "locations": [ - "app/server/db/git.go:660" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Retry delay configuration", - "category": "retry", - "description": "Retry logic using retry delay configuration", - "locations": [ - "app/server/db/git.go:21", - "app/server/db/git.go:660" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Backoff patterns", - "category": "retry", - "description": "Retry logic using backoff patterns", - "locations": [ - "app/server/db/locks.go:31", - "app/server/db/locks.go:32", - "app/server/db/locks.go:34", - "app/server/db/locks.go:163", - "app/server/db/locks.go:185", - "app/server/db/locks.go:287", - "app/server/db/locks.go:344", - "app/server/db/locks.go:345", - "app/server/db/locks.go:364", - "app/server/db/locks.go:564", - "app/server/db/locks.go:577", - "app/server/db/locks.go:579", - "app/server/db/locks.go:582", - "app/server/db/locks.go:604" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Retry delay configuration", - "category": "retry", - "description": "Retry logic using retry delay configuration", - "locations": [ - "app/server/db/locks.go:30", - "app/server/db/locks.go:36", - "app/server/db/locks.go:576", - "app/server/db/locks.go:577", - "app/server/db/locks.go:608" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/handlers/plans_changes.go:39", - "app/server/handlers/plans_changes.go:143" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/handlers/plans_exec.go:296" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/handlers/stream_helper.go:53", - "app/server/handlers/stream_helper.go:69", - "app/server/handlers/stream_helper.go:71" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Max retry configuration", - "category": "retry", - "description": "Retry logic using max retry configuration", - "locations": [ - "app/server/model/client_stream.go:277", - "app/server/model/client_stream.go:279", - "app/server/model/client_stream.go:291", - "app/server/model/client_stream.go:316", - "app/server/model/client_stream.go:317" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Retry delay configuration", - "category": "retry", - "description": "Retry logic using retry delay configuration", - "locations": [ - "app/server/model/client_stream.go:321", - "app/server/model/client_stream.go:324", - "app/server/model/client_stream.go:327", - "app/server/model/client_stream.go:330", - "app/server/model/client_stream.go:331" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/activate.go:29" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/build_exec.go:350" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Backoff patterns", - "category": "retry", - "description": "Retry logic using backoff patterns", - "locations": [ - "app/server/model/plan/build_state.go:14" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/build_structured_edits.go:190" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/state.go:83" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/tell_exec.go:132" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Max retry configuration", - "category": "retry", - "description": "Retry logic using max retry configuration", - "locations": [ - "app/server/model/plan/tell_stream_error.go:59", - "app/server/model/plan/tell_stream_error.go:61", - "app/server/model/plan/tell_stream_error.go:97", - "app/server/model/plan/tell_stream_error.go:127", - "app/server/model/plan/tell_stream_error.go:244" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Retry delay configuration", - "category": "retry", - "description": "Retry logic using retry delay configuration", - "locations": [ - "app/server/model/plan/tell_stream_error.go:111", - "app/server/model/plan/tell_stream_error.go:114", - "app/server/model/plan/tell_stream_error.go:117", - "app/server/model/plan/tell_stream_error.go:127", - "app/server/model/plan/tell_stream_error.go:128" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/tell_stream_finish.go:52", - "app/server/model/plan/tell_stream_finish.go:54", - "app/server/model/plan/tell_stream_finish.go:233" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/model/plan/tell_stream_processor.go:663" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Max retry configuration", - "category": "retry", - "description": "Retry logic using max retry configuration", - "locations": [ - "app/server/syntax/file_map/examples/go_example.go:43" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - }, - { - "name": "Retry: Exponential backoff", - "category": "retry", - "description": "Retry logic using exponential backoff", - "locations": [ - "app/server/types/active_plan.go:271", - "app/server/types/active_plan.go:285", - "app/server/types/active_plan.go:307" - ], - "triggers": [], - "timing": "Exponential backoff common", - "concurrency": null, - "failure_handling": "Max attempts then fail", - "python_considerations": [ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern" - ] - } - ], - "validation": [ - { - "name": "Validation: Validation functions", - "category": "validation", - "description": "Input validation via validation functions", - "locations": [ - "app/cli/cmd/plan_exec_helpers.go:131", - "app/cli/cmd/plan_exec_helpers.go:218", - "app/cli/schema/schemas.go:36", - "app/cli/schema/schemas.go:37", - "app/cli/schema/schemas.go:40", - "app/cli/schema/schemas.go:41", - "app/cli/schema/schemas.go:44", - "app/server/db/auth_helpers.go:33", - "app/server/db/auth_helpers.go:80", - "app/server/db/auth_helpers.go:81" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: Sanitization functions", - "category": "validation", - "description": "Input validation via sanitization functions", - "locations": [ - "app/cli/url/url.go:70", - "app/cli/url/url.go:76", - "app/cli/url/url.go:77", - "app/cli/url/url.go:78", - "app/cli/url/url.go:79", - "app/cli/url/url.go:80", - "app/cli/url/url.go:81", - "app/cli/url/url.go:82", - "app/cli/url/url.go:83", - "app/cli/url/url.go:84" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: Empty string checks", - "category": "validation", - "description": "Input validation via empty string checks", - "locations": [ - "app/cli/api/clients.go:26", - "app/cli/api/methods.go:1259", - "app/cli/api/methods.go:1291", - "app/cli/api/methods.go:1662", - "app/cli/auth/auth.go:58", - "app/cli/auth/auth.go:73", - "app/cli/auth/auth.go:104", - "app/cli/cmd/apply.go:45", - "app/cli/cmd/archive.go:54", - "app/cli/cmd/branches.go:33" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: String trimming", - "category": "validation", - "description": "Input validation via string trimming", - "locations": [ - "app/cli/upgrade.go:60", - "app/cli/api/errors.go:20", - "app/cli/api/errors.go:30", - "app/cli/cmd/archive.go:36", - "app/cli/cmd/cd.go:37", - "app/cli/cmd/checkout.go:50", - "app/cli/cmd/delete_branch.go:40", - "app/cli/cmd/delete_plan.go:91", - "app/cli/cmd/repl.go:316", - "app/cli/cmd/repl.go:319" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: Regex validation", - "category": "validation", - "description": "Input validation via regex validation", - "locations": [ - "app/cli/cmd/convo.go:178", - "app/cli/cmd/repl.go:488", - "app/cli/cmd/rewind.go:91", - "app/cli/cmd/rewind.go:503", - "app/cli/url/url.go:72", - "app/server/model/model_error.go:25", - "app/server/model/model_error.go:28", - "app/server/model/model_error.go:34", - "app/server/model/plan/tell_context.go:368", - "app/server/model/plan/tell_stream_processor.go:22" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - }, - { - "name": "Validation: Validation errors", - "category": "validation", - "description": "Input validation via validation errors", - "locations": [ - "app/server/db/auth_helpers.go:38", - "app/server/db/auth_helpers.go:51", - "app/server/model/prompts/explanation_format.go:456", - "app/server/model/prompts/explanation_format.go:482", - "app/server/model/prompts/explanation_format.go:680", - "app/server/model/prompts/explanation_format.go:709" - ], - "triggers": [ - "User input", - "API requests" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators" - ] - } - ], - "concurrency": [ - { - "name": "Concurrency: Anonymous goroutines", - "category": "concurrency", - "description": "Concurrent execution via anonymous goroutines", - "locations": [ - "app/cli/api/stream.go:24", - "app/cli/cmd/connect.go:52", - "app/cli/cmd/debug.go:109", - "app/cli/cmd/debug.go:161", - "app/cli/cmd/diffs.go:119", - "app/cli/cmd/models.go:103", - "app/cli/cmd/models.go:113", - "app/cli/cmd/new.go:50", - "app/cli/cmd/new.go:60", - "app/cli/cmd/plans.go:61" - ], - "triggers": [], - "timing": null, - "concurrency": "Go anonymous goroutines", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Named goroutine calls", - "category": "concurrency", - "description": "Concurrent execution via named goroutine calls", - "locations": [ - "app/cli/api/stream.go:24", - "app/cli/cmd/connect.go:52", - "app/cli/cmd/debug.go:109", - "app/cli/cmd/debug.go:161", - "app/cli/cmd/diffs.go:119", - "app/cli/cmd/models.go:103", - "app/cli/cmd/models.go:113", - "app/cli/cmd/new.go:50", - "app/cli/cmd/new.go:60", - "app/cli/cmd/plans.go:61" - ], - "triggers": [], - "timing": null, - "concurrency": "Go named goroutine calls", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Channel declarations", - "category": "concurrency", - "description": "Concurrent execution via channel declarations", - "locations": [ - "app/cli/cmd/browser.go:168", - "app/cli/cmd/browser.go:171", - "app/cli/cmd/debug.go:105", - "app/cli/cmd/models.go:101", - "app/cli/cmd/new.go:45", - "app/cli/cmd/plans.go:56", - "app/cli/cmd/revoke.go:35", - "app/cli/cmd/set_model.go:159", - "app/cli/cmd/tell.go:224", - "app/cli/cmd/users.go:33" - ], - "triggers": [], - "timing": null, - "concurrency": "Go channel declarations", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Select statements", - "category": "concurrency", - "description": "Concurrent execution via select statements", - "locations": [ - "app/cli/api/stream.go:26", - "app/cli/cmd/browser.go:225", - "app/cli/cmd/connect.go:66", - "app/cli/cmd/debug.go:112", - "app/cli/cmd/debug.go:140", - "app/cli/cmd/reject.go:127", - "app/cli/fs/projects.go:73", - "app/cli/term/select.go:13", - "app/server/db/convo_helpers.go:68", - "app/server/db/locks.go:80" - ], - "triggers": [], - "timing": null, - "concurrency": "Go select statements", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Channel receive", - "category": "concurrency", - "description": "Concurrent execution via channel receive", - "locations": [ - "app/cli/api/stream.go:27", - "app/cli/cmd/browser.go:226", - "app/cli/cmd/browser.go:229", - "app/cli/cmd/browser.go:232", - "app/cli/cmd/debug.go:113", - "app/cli/cmd/debug.go:141", - "app/cli/cmd/debug.go:147", - "app/cli/cmd/debug.go:152", - "app/cli/cmd/models.go:124", - "app/cli/cmd/new.go:71" - ], - "triggers": [], - "timing": null, - "concurrency": "Go channel receive", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: Channel send", - "category": "concurrency", - "description": "Concurrent execution via channel send", - "locations": [ - "app/cli/api/stream.go:27", - "app/cli/cmd/browser.go:194", - "app/cli/cmd/browser.go:202", - "app/cli/cmd/browser.go:226", - "app/cli/cmd/browser.go:229", - "app/cli/cmd/browser.go:232", - "app/cli/cmd/debug.go:141", - "app/cli/cmd/debug.go:147", - "app/cli/cmd/debug.go:152", - "app/cli/cmd/models.go:107" - ], - "triggers": [], - "timing": null, - "concurrency": "Go channel send", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - }, - { - "name": "Concurrency: WaitGroup usage", - "category": "concurrency", - "description": "Concurrent execution via waitgroup usage", - "locations": [ - "app/cli/cmd/debug.go:103", - "app/cli/stream_tui/run.go:18", - "app/server/db/queue.go:227", - "app/server/handlers/file_maps_queue.go:84", - "app/server/syntax/file_map/examples/go_example.go:153" - ], - "triggers": [], - "timing": null, - "concurrency": "Go waitgroup usage", - "failure_handling": null, - "python_considerations": [ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks" - ] - } - ], - "streaming": [ - { - "name": "Streaming: Stream operations", - "category": "streaming", - "description": "Real-time data streaming via stream operations", - "locations": [ - "app/cli/cmd/connect.go:45", - "app/cli/plan_exec/build.go:56", - "app/cli/plan_exec/tell.go:151", - "app/server/db/stream_helpers.go:38", - "app/server/db/stream_helpers.go:39", - "app/server/db/stream_helpers.go:56", - "app/server/db/stream_helpers.go:58", - "app/server/db/stream_helpers.go:63", - "app/server/db/stream_helpers.go:111", - "app/server/db/stream_helpers.go:112" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Streaming: Server-sent events", - "category": "streaming", - "description": "Real-time data streaming via server-sent events", - "locations": [ - "app/cli/api/stream.go:16", - "app/cli/cmd/browser.go:89", - "app/cli/cmd/debug.go:123", - "app/cli/cmd/plan_exec_helpers.go:113", - "app/cli/cmd/plan_exec_helpers.go:118", - "app/cli/cmd/rewind.go:27", - "app/cli/cmd/rewind.go:28", - "app/cli/cmd/rewind.go:29", - "app/cli/cmd/rewind.go:48", - "app/cli/cmd/rewind.go:49" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Streaming: Stream copying", - "category": "streaming", - "description": "Real-time data streaming via stream copying", - "locations": [ - "app/cli/upgrade.go:118", - "app/server/handlers/proxy_helper.go:102" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Streaming: Buffered I/O", - "category": "streaming", - "description": "Real-time data streaming via buffered i/o", - "locations": [ - "app/cli/api/stream.go:20", - "app/cli/api/stream.go:72", - "app/cli/cmd/debug.go:160", - "app/cli/cmd/tell.go:123", - "app/server/diff/diff.go:74", - "app/server/model/client.go:91", - "app/server/model/client.go:386" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - }, - { - "name": "Streaming: Stream flushing", - "category": "streaming", - "description": "Real-time data streaming via stream flushing", - "locations": [ - "app/server/handlers/stream_helper.go:122" - ], - "triggers": [], - "timing": "Real-time/low-latency", - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming" - ] - } - ], - "telemetry": [ - { - "name": "Telemetry: Metrics collection", - "category": "telemetry", - "description": "Usage tracking via metrics collection", - "locations": [ - "app/server/syntax/structured_edits_test.go:123", - "app/server/syntax/structured_edits_test.go:150" - ], - "triggers": [ - "Command execution", - "Feature usage" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Make telemetry opt-in by default", - "Use structured logging for metrics", - "Consider OpenTelemetry for standards", - "Respect privacy settings strictly" - ] - }, - { - "name": "Telemetry: Tracking functions", - "category": "telemetry", - "description": "Usage tracking via tracking functions", - "locations": [ - "app/cli/fs/paths.go:91", - "app/cli/fs/paths.go:130", - "app/cli/fs/paths.go:138", - "app/cli/fs/paths.go:180", - "app/server/db/git.go:372", - "app/server/db/git.go:373", - "app/server/db/git.go:376", - "app/server/db/git.go:378", - "app/server/db/git.go:689", - "app/server/types/message.go:265" - ], - "triggers": [ - "Command execution", - "Feature usage" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Make telemetry opt-in by default", - "Use structured logging for metrics", - "Consider OpenTelemetry for standards", - "Respect privacy settings strictly" - ] - }, - { - "name": "Telemetry: Usage tracking", - "category": "telemetry", - "description": "Usage tracking via usage tracking", - "locations": [ - "app/server/model/model_request.go:204", - "app/server/model/model_request.go:205", - "app/server/model/model_request.go:207", - "app/server/model/model_request.go:208", - "app/server/model/summarize.go:88", - "app/server/model/plan/tell_stream_usage.go:23", - "app/server/model/plan/tell_stream_usage.go:24", - "app/server/model/plan/tell_stream_usage.go:44", - "app/server/model/plan/tell_stream_usage.go:45" - ], - "triggers": [ - "Command execution", - "Feature usage" - ], - "timing": null, - "concurrency": null, - "failure_handling": null, - "python_considerations": [ - "Make telemetry opt-in by default", - "Use structured logging for metrics", - "Consider OpenTelemetry for standards", - "Respect privacy settings strictly" - ] - } - ] - }, - "statistics": { - "total_behaviors": 61, - "categories": [ - "auto-context", - "locking", - "retry", - "validation", - "concurrency", - "streaming", - "telemetry" - ], - "behaviors_per_category": { - "auto-context": 2, - "locking": 5, - "retry": 33, - "validation": 6, - "concurrency": 7, - "streaming": 5, - "telemetry": 3 - }, - "python_migration_considerations": [ - "Apply validators as decorators", - "Consider OpenTelemetry for standards", - "Consider Server-Sent Events for unidirectional", - "Consider asyncio for concurrent context loads", - "Consider asyncio.wait_for for timeouts", - "Consider fcntl for file locks", - "Consider marshmallow for serialization", - "Consider threading for CPU-bound tasks", - "Implement circuit breaker pattern", - "Implement proper backpressure handling", - "Make telemetry opt-in by default", - "Queue.Queue for channel-like behavior", - "Respect privacy settings strictly", - "Use Python decorators for auto-loading", - "Use aiohttp for WebSocket support", - "Use async generators for streaming", - "Use asyncio tasks for coroutines", - "Use context managers for automatic cleanup", - "Use pydantic for data validation", - "Use structured logging for metrics", - "Use tenacity or backoff libraries", - "Use threading.Lock or asyncio.Lock", - "asyncio.gather for WaitGroup equivalent" - ] - }, - "sequence_diagrams": { - "auto_context_loading": "User -> CLI: Execute command with @context\nCLI -> ContextLoader: Parse @ reference\nContextLoader -> FileSystem: Load context file\nFileSystem -> ContextLoader: Return content\nContextLoader -> CLI: Inject context\nCLI -> Server: Execute with context", - "retry_with_backoff": "Client -> Service: Make request\nService -> Provider: Call API\nProvider -> Service: Error/Timeout\nService -> Service: Wait (exponential backoff)\nService -> Provider: Retry request\nProvider -> Service: Success\nService -> Client: Return result", - "git_locking": "CLI -> LockManager: Acquire git lock\nLockManager -> FileSystem: Create lock file\nFileSystem -> LockManager: Lock acquired\nLockManager -> CLI: Proceed\nCLI -> Git: Execute operations\nGit -> CLI: Complete\nCLI -> LockManager: Release lock\nLockManager -> FileSystem: Remove lock file" - } -} \ No newline at end of file diff --git a/docs/reference/behaviors/implicit_behaviors.md b/docs/reference/behaviors/implicit_behaviors.md deleted file mode 100644 index af392c381..000000000 --- a/docs/reference/behaviors/implicit_behaviors.md +++ /dev/null @@ -1,686 +0,0 @@ -# Implicit Behaviors in Plandex - -## Summary - -- Total behaviors identified: 61 -- Categories: auto-context, locking, retry, validation, concurrency, streaming, telemetry - -## Behaviors by Category - -### Auto-Context - -#### Auto-Context: Auto-load context configuration -- **Description**: Automatic context loading based on auto-load context configuration -- **Triggers**: CLI command execution, @ symbol in input -- **Example Locations**: app/cli/api/methods.go:2386, app/cli/cmd/ls.go:96, app/cli/cmd/new.go:104 -- **Python Migration Notes**: - - Use Python decorators for auto-loading - - Consider asyncio for concurrent context loads - -#### Auto-Context: At-symbol context references -- **Description**: Automatic context loading based on at-symbol context references -- **Triggers**: CLI command execution, @ symbol in input -- **Example Locations**: app/cli/auth/account.go:189, app/cli/auth/trial.go:38, app/cli/auth/trial.go:86 -- **Python Migration Notes**: - - Use Python decorators for auto-loading - - Consider asyncio for concurrent context loads - -### Locking - -#### Locking: Explicit lock acquisition -- **Description**: Resource locking via explicit lock acquisition -- **Concurrency**: Go mutexes/file locks -- **Failure Handling**: Deferred unlock ensures cleanup -- **Example Locations**: app/server/db/context_helpers_get.go:46, app/server/db/context_helpers_get.go:47, app/server/db/context_helpers_load.go:337 -- **Python Migration Notes**: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - -#### Locking: Lock release -- **Description**: Resource locking via lock release -- **Concurrency**: Go mutexes/file locks -- **Failure Handling**: Deferred unlock ensures cleanup -- **Example Locations**: app/server/db/context_helpers_get.go:47, app/server/db/context_helpers_load.go:342, app/server/db/context_helpers_update.go:164 -- **Python Migration Notes**: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - -#### Locking: Mutex usage -- **Description**: Resource locking via mutex usage -- **Concurrency**: Go mutexes/file locks -- **Failure Handling**: Deferred unlock ensures cleanup -- **Example Locations**: app/server/db/context_helpers_get.go:31, app/server/db/context_helpers_load.go:288, app/server/db/context_helpers_update.go:137 -- **Python Migration Notes**: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - -#### Locking: File-based locking -- **Description**: Resource locking via file-based locking -- **Concurrency**: Go mutexes/file locks -- **Failure Handling**: Deferred unlock ensures cleanup -- **Example Locations**: app/server/db/git.go:404, app/server/db/git.go:416, app/server/db/git.go:430 -- **Python Migration Notes**: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - -#### Locking: Deferred unlock patterns -- **Description**: Resource locking via deferred unlock patterns -- **Concurrency**: Go mutexes/file locks -- **Failure Handling**: Deferred unlock ensures cleanup -- **Example Locations**: app/server/db/context_helpers_get.go:47, app/server/db/context_helpers_update.go:164, app/server/db/queue.go:44 -- **Python Migration Notes**: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - -### Retry - -#### Retry: Manual retry loops -- **Description**: Retry logic using manual retry loops -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/api/clients.go:82 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Backoff patterns -- **Description**: Retry logic using backoff patterns -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/api/clients.go:108, app/cli/api/clients.go:109, app/cli/api/clients.go:110 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Max retry configuration -- **Description**: Retry logic using max retry configuration -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/api/clients.go:68, app/cli/api/clients.go:82, app/cli/api/clients.go:104 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/auth/trial.go:34, app/cli/auth/trial.go:82 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/cmd/cd.go:113 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Manual retry loops -- **Description**: Retry logic using manual retry loops -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/cmd/debug.go:78 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/cmd/tell.go:252 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/plan_exec/tell.go:239 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/stream_tui/update.go:569 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/cli/term/spinner.go:66, app/cli/term/spinner.go:72 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Manual retry loops -- **Description**: Retry logic using manual retry loops -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/db/git.go:658 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/db/git.go:598 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Backoff patterns -- **Description**: Retry logic using backoff patterns -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/db/git.go:660 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Retry delay configuration -- **Description**: Retry logic using retry delay configuration -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/db/git.go:21, app/server/db/git.go:660 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Backoff patterns -- **Description**: Retry logic using backoff patterns -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/db/locks.go:31, app/server/db/locks.go:32, app/server/db/locks.go:34 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Retry delay configuration -- **Description**: Retry logic using retry delay configuration -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/db/locks.go:30, app/server/db/locks.go:36, app/server/db/locks.go:576 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/handlers/plans_changes.go:39, app/server/handlers/plans_changes.go:143 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/handlers/plans_exec.go:296 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/handlers/stream_helper.go:53, app/server/handlers/stream_helper.go:69, app/server/handlers/stream_helper.go:71 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Max retry configuration -- **Description**: Retry logic using max retry configuration -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/client_stream.go:277, app/server/model/client_stream.go:279, app/server/model/client_stream.go:291 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Retry delay configuration -- **Description**: Retry logic using retry delay configuration -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/client_stream.go:321, app/server/model/client_stream.go:324, app/server/model/client_stream.go:327 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/activate.go:29 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/build_exec.go:350 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Backoff patterns -- **Description**: Retry logic using backoff patterns -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/build_state.go:14 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/build_structured_edits.go:190 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/state.go:83 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/tell_exec.go:132 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Max retry configuration -- **Description**: Retry logic using max retry configuration -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/tell_stream_error.go:59, app/server/model/plan/tell_stream_error.go:61, app/server/model/plan/tell_stream_error.go:97 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Retry delay configuration -- **Description**: Retry logic using retry delay configuration -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/tell_stream_error.go:111, app/server/model/plan/tell_stream_error.go:114, app/server/model/plan/tell_stream_error.go:117 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/tell_stream_finish.go:52, app/server/model/plan/tell_stream_finish.go:54, app/server/model/plan/tell_stream_finish.go:233 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/model/plan/tell_stream_processor.go:663 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Max retry configuration -- **Description**: Retry logic using max retry configuration -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/syntax/file_map/examples/go_example.go:43 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -#### Retry: Exponential backoff -- **Description**: Retry logic using exponential backoff -- **Timing**: Exponential backoff common -- **Failure Handling**: Max attempts then fail -- **Example Locations**: app/server/types/active_plan.go:271, app/server/types/active_plan.go:285, app/server/types/active_plan.go:307 -- **Python Migration Notes**: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - -### Validation - -#### Validation: Validation functions -- **Description**: Input validation via validation functions -- **Triggers**: User input, API requests -- **Example Locations**: app/cli/cmd/plan_exec_helpers.go:131, app/cli/cmd/plan_exec_helpers.go:218, app/cli/schema/schemas.go:36 -- **Python Migration Notes**: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - -#### Validation: Sanitization functions -- **Description**: Input validation via sanitization functions -- **Triggers**: User input, API requests -- **Example Locations**: app/cli/url/url.go:70, app/cli/url/url.go:76, app/cli/url/url.go:77 -- **Python Migration Notes**: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - -#### Validation: Empty string checks -- **Description**: Input validation via empty string checks -- **Triggers**: User input, API requests -- **Example Locations**: app/cli/api/clients.go:26, app/cli/api/methods.go:1259, app/cli/api/methods.go:1291 -- **Python Migration Notes**: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - -#### Validation: String trimming -- **Description**: Input validation via string trimming -- **Triggers**: User input, API requests -- **Example Locations**: app/cli/upgrade.go:60, app/cli/api/errors.go:20, app/cli/api/errors.go:30 -- **Python Migration Notes**: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - -#### Validation: Regex validation -- **Description**: Input validation via regex validation -- **Triggers**: User input, API requests -- **Example Locations**: app/cli/cmd/convo.go:178, app/cli/cmd/repl.go:488, app/cli/cmd/rewind.go:91 -- **Python Migration Notes**: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - -#### Validation: Validation errors -- **Description**: Input validation via validation errors -- **Triggers**: User input, API requests -- **Example Locations**: app/server/db/auth_helpers.go:38, app/server/db/auth_helpers.go:51, app/server/model/prompts/explanation_format.go:456 -- **Python Migration Notes**: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - -### Concurrency - -#### Concurrency: Anonymous goroutines -- **Description**: Concurrent execution via anonymous goroutines -- **Concurrency**: Go anonymous goroutines -- **Example Locations**: app/cli/api/stream.go:24, app/cli/cmd/connect.go:52, app/cli/cmd/debug.go:109 -- **Python Migration Notes**: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - -#### Concurrency: Named goroutine calls -- **Description**: Concurrent execution via named goroutine calls -- **Concurrency**: Go named goroutine calls -- **Example Locations**: app/cli/api/stream.go:24, app/cli/cmd/connect.go:52, app/cli/cmd/debug.go:109 -- **Python Migration Notes**: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - -#### Concurrency: Channel declarations -- **Description**: Concurrent execution via channel declarations -- **Concurrency**: Go channel declarations -- **Example Locations**: app/cli/cmd/browser.go:168, app/cli/cmd/browser.go:171, app/cli/cmd/debug.go:105 -- **Python Migration Notes**: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - -#### Concurrency: Select statements -- **Description**: Concurrent execution via select statements -- **Concurrency**: Go select statements -- **Example Locations**: app/cli/api/stream.go:26, app/cli/cmd/browser.go:225, app/cli/cmd/connect.go:66 -- **Python Migration Notes**: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - -#### Concurrency: Channel receive -- **Description**: Concurrent execution via channel receive -- **Concurrency**: Go channel receive -- **Example Locations**: app/cli/api/stream.go:27, app/cli/cmd/browser.go:226, app/cli/cmd/browser.go:229 -- **Python Migration Notes**: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - -#### Concurrency: Channel send -- **Description**: Concurrent execution via channel send -- **Concurrency**: Go channel send -- **Example Locations**: app/cli/api/stream.go:27, app/cli/cmd/browser.go:194, app/cli/cmd/browser.go:202 -- **Python Migration Notes**: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - -#### Concurrency: WaitGroup usage -- **Description**: Concurrent execution via waitgroup usage -- **Concurrency**: Go waitgroup usage -- **Example Locations**: app/cli/cmd/debug.go:103, app/cli/stream_tui/run.go:18, app/server/db/queue.go:227 -- **Python Migration Notes**: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - -### Streaming - -#### Streaming: Stream operations -- **Description**: Real-time data streaming via stream operations -- **Timing**: Real-time/low-latency -- **Example Locations**: app/cli/cmd/connect.go:45, app/cli/plan_exec/build.go:56, app/cli/plan_exec/tell.go:151 -- **Python Migration Notes**: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - -#### Streaming: Server-sent events -- **Description**: Real-time data streaming via server-sent events -- **Timing**: Real-time/low-latency -- **Example Locations**: app/cli/api/stream.go:16, app/cli/cmd/browser.go:89, app/cli/cmd/debug.go:123 -- **Python Migration Notes**: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - -#### Streaming: Stream copying -- **Description**: Real-time data streaming via stream copying -- **Timing**: Real-time/low-latency -- **Example Locations**: app/cli/upgrade.go:118, app/server/handlers/proxy_helper.go:102 -- **Python Migration Notes**: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - -#### Streaming: Buffered I/O -- **Description**: Real-time data streaming via buffered i/o -- **Timing**: Real-time/low-latency -- **Example Locations**: app/cli/api/stream.go:20, app/cli/api/stream.go:72, app/cli/cmd/debug.go:160 -- **Python Migration Notes**: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - -#### Streaming: Stream flushing -- **Description**: Real-time data streaming via stream flushing -- **Timing**: Real-time/low-latency -- **Example Locations**: app/server/handlers/stream_helper.go:122 -- **Python Migration Notes**: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - -### Telemetry - -#### Telemetry: Metrics collection -- **Description**: Usage tracking via metrics collection -- **Triggers**: Command execution, Feature usage -- **Example Locations**: app/server/syntax/structured_edits_test.go:123, app/server/syntax/structured_edits_test.go:150 -- **Python Migration Notes**: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly - -#### Telemetry: Tracking functions -- **Description**: Usage tracking via tracking functions -- **Triggers**: Command execution, Feature usage -- **Example Locations**: app/cli/fs/paths.go:91, app/cli/fs/paths.go:130, app/cli/fs/paths.go:138 -- **Python Migration Notes**: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly - -#### Telemetry: Usage tracking -- **Description**: Usage tracking via usage tracking -- **Triggers**: Command execution, Feature usage -- **Example Locations**: app/server/model/model_request.go:204, app/server/model/model_request.go:205, app/server/model/model_request.go:207 -- **Python Migration Notes**: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly - -## Sequence Diagrams - -### Auto Context Loading -```mermaid -sequenceDiagram - User -> CLI: Execute command with @context - CLI -> ContextLoader: Parse @ reference - ContextLoader -> FileSystem: Load context file - FileSystem -> ContextLoader: Return content - ContextLoader -> CLI: Inject context - CLI -> Server: Execute with context -``` - -### Retry With Backoff -```mermaid -sequenceDiagram - Client -> Service: Make request - Service -> Provider: Call API - Provider -> Service: Error/Timeout - Service -> Service: Wait (exponential backoff) - Service -> Provider: Retry request - Provider -> Service: Success - Service -> Client: Return result -``` - -### Git Locking -```mermaid -sequenceDiagram - CLI -> LockManager: Acquire git lock - LockManager -> FileSystem: Create lock file - FileSystem -> LockManager: Lock acquired - LockManager -> CLI: Proceed - CLI -> Git: Execute operations - Git -> CLI: Complete - CLI -> LockManager: Release lock - LockManager -> FileSystem: Remove lock file -``` - -## Python Migration Considerations - -- Apply validators as decorators -- Consider OpenTelemetry for standards -- Consider Server-Sent Events for unidirectional -- Consider asyncio for concurrent context loads -- Consider asyncio.wait_for for timeouts -- Consider fcntl for file locks -- Consider marshmallow for serialization -- Consider threading for CPU-bound tasks -- Implement circuit breaker pattern -- Implement proper backpressure handling -- Make telemetry opt-in by default -- Queue.Queue for channel-like behavior -- Respect privacy settings strictly -- Use Python decorators for auto-loading -- Use aiohttp for WebSocket support -- Use async generators for streaming -- Use asyncio tasks for coroutines -- Use context managers for automatic cleanup -- Use pydantic for data validation -- Use structured logging for metrics -- Use tenacity or backoff libraries -- Use threading.Lock or asyncio.Lock -- asyncio.gather for WaitGroup equivalent diff --git a/docs/reference/behaviors/implicit_behaviors.yaml b/docs/reference/behaviors/implicit_behaviors.yaml deleted file mode 100644 index 9d37f21a3..000000000 --- a/docs/reference/behaviors/implicit_behaviors.yaml +++ /dev/null @@ -1,2293 +0,0 @@ -behaviors: -- name: 'Auto-Context: Auto-load context configuration' - category: auto-context - description: Automatic context loading based on auto-load context configuration - locations: - - app/cli/api/methods.go:2386 - - app/cli/cmd/ls.go:96 - - app/cli/cmd/new.go:104 - - app/cli/cmd/new.go:128 - - app/cli/cmd/plan_exec_helpers.go:187 - - app/cli/cmd/plan_start_helpers.go:218 - - app/cli/cmd/repl.go:833 - - app/cli/cmd/set_config.go:333 - - app/cli/cmd/set_config.go:356 - - app/cli/stream_tui/model.go:84 - triggers: - - CLI command execution - - '@ symbol in input' - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use Python decorators for auto-loading - - Consider asyncio for concurrent context loads -- name: 'Auto-Context: At-symbol context references' - category: auto-context - description: Automatic context loading based on at-symbol context references - locations: - - app/cli/auth/account.go:189 - - app/cli/auth/trial.go:38 - - app/cli/auth/trial.go:86 - triggers: - - CLI command execution - - '@ symbol in input' - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use Python decorators for auto-loading - - Consider asyncio for concurrent context loads -- name: 'Locking: Explicit lock acquisition' - category: locking - description: Resource locking via explicit lock acquisition - locations: - - app/server/db/context_helpers_get.go:46 - - app/server/db/context_helpers_get.go:47 - - app/server/db/context_helpers_load.go:337 - - app/server/db/context_helpers_load.go:342 - - app/server/db/context_helpers_update.go:163 - - app/server/db/context_helpers_update.go:164 - - app/server/db/context_helpers_update.go:316 - - app/server/db/context_helpers_update.go:325 - - app/server/db/locks.go:381 - - app/server/db/locks.go:383 - - app/server/db/locks.go:516 - - app/server/db/locks.go:518 - - app/server/db/locks.go:662 - - app/server/db/locks.go:664 - - app/server/db/queue.go:43 - - app/server/db/queue.go:44 - - app/server/db/queue.go:72 - - app/server/db/queue.go:90 - - app/server/db/queue.go:96 - - app/server/db/queue.go:97 - - app/server/db/queue.go:163 - - app/server/db/queue.go:165 - - app/server/db/result_helpers.go:1070 - - app/server/db/result_helpers.go:1072 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup -- name: 'Locking: Lock release' - category: locking - description: Resource locking via lock release - locations: - - app/server/db/context_helpers_get.go:47 - - app/server/db/context_helpers_load.go:342 - - app/server/db/context_helpers_update.go:164 - - app/server/db/context_helpers_update.go:325 - - app/server/db/locks.go:383 - - app/server/db/locks.go:518 - - app/server/db/locks.go:664 - - app/server/db/queue.go:44 - - app/server/db/queue.go:90 - - app/server/db/queue.go:97 - - app/server/db/queue.go:165 - - app/server/db/result_helpers.go:1072 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup -- name: 'Locking: Mutex usage' - category: locking - description: Resource locking via mutex usage - locations: - - app/server/db/context_helpers_get.go:31 - - app/server/db/context_helpers_load.go:288 - - app/server/db/context_helpers_update.go:137 - - app/server/db/locks.go:39 - - app/server/db/queue.go:33 - - app/server/db/queue.go:39 - - app/server/db/result_helpers.go:1042 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup -- name: 'Locking: File-based locking' - category: locking - description: Resource locking via file-based locking - locations: - - app/server/db/git.go:404 - - app/server/db/git.go:416 - - app/server/db/git.go:430 - - app/server/db/git.go:557 - - app/server/db/git.go:558 - - app/server/db/git.go:571 - - app/server/db/git.go:573 - - app/server/db/git.go:575 - - app/server/db/git.go:582 - - app/server/db/git.go:589 - - app/server/db/git.go:591 - - app/server/db/git.go:593 - - app/server/db/git.go:604 - - app/server/db/git.go:605 - - app/server/db/git.go:619 - - app/server/db/git.go:620 - - app/server/db/git.go:624 - - app/server/db/git.go:673 - - app/server/db/locks.go:461 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup -- name: 'Locking: Deferred unlock patterns' - category: locking - description: Resource locking via deferred unlock patterns - locations: - - app/server/db/context_helpers_get.go:47 - - app/server/db/context_helpers_update.go:164 - - app/server/db/queue.go:44 - - app/server/db/queue.go:97 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup -- name: 'Retry: Manual retry loops' - category: retry - description: Retry logic using manual retry loops - locations: - - app/cli/api/clients.go:82 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Backoff patterns' - category: retry - description: Retry logic using backoff patterns - locations: - - app/cli/api/clients.go:108 - - app/cli/api/clients.go:109 - - app/cli/api/clients.go:110 - - app/cli/api/clients.go:111 - - app/cli/api/clients.go:113 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Max retry configuration' - category: retry - description: Retry logic using max retry configuration - locations: - - app/cli/api/clients.go:68 - - app/cli/api/clients.go:82 - - app/cli/api/clients.go:104 - - app/cli/api/clients.go:129 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/auth/trial.go:34 - - app/cli/auth/trial.go:82 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/cmd/cd.go:113 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Manual retry loops' - category: retry - description: Retry logic using manual retry loops - locations: - - app/cli/cmd/debug.go:78 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/cmd/tell.go:252 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/plan_exec/tell.go:239 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/stream_tui/update.go:569 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/term/spinner.go:66 - - app/cli/term/spinner.go:72 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Manual retry loops' - category: retry - description: Retry logic using manual retry loops - locations: - - app/server/db/git.go:658 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/db/git.go:598 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Backoff patterns' - category: retry - description: Retry logic using backoff patterns - locations: - - app/server/db/git.go:660 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Retry delay configuration' - category: retry - description: Retry logic using retry delay configuration - locations: - - app/server/db/git.go:21 - - app/server/db/git.go:660 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Backoff patterns' - category: retry - description: Retry logic using backoff patterns - locations: - - app/server/db/locks.go:31 - - app/server/db/locks.go:32 - - app/server/db/locks.go:34 - - app/server/db/locks.go:163 - - app/server/db/locks.go:185 - - app/server/db/locks.go:287 - - app/server/db/locks.go:344 - - app/server/db/locks.go:345 - - app/server/db/locks.go:364 - - app/server/db/locks.go:564 - - app/server/db/locks.go:577 - - app/server/db/locks.go:579 - - app/server/db/locks.go:582 - - app/server/db/locks.go:604 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Retry delay configuration' - category: retry - description: Retry logic using retry delay configuration - locations: - - app/server/db/locks.go:30 - - app/server/db/locks.go:36 - - app/server/db/locks.go:576 - - app/server/db/locks.go:577 - - app/server/db/locks.go:608 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/handlers/plans_changes.go:39 - - app/server/handlers/plans_changes.go:143 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/handlers/plans_exec.go:296 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/handlers/stream_helper.go:53 - - app/server/handlers/stream_helper.go:69 - - app/server/handlers/stream_helper.go:71 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Max retry configuration' - category: retry - description: Retry logic using max retry configuration - locations: - - app/server/model/client_stream.go:277 - - app/server/model/client_stream.go:279 - - app/server/model/client_stream.go:291 - - app/server/model/client_stream.go:316 - - app/server/model/client_stream.go:317 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Retry delay configuration' - category: retry - description: Retry logic using retry delay configuration - locations: - - app/server/model/client_stream.go:321 - - app/server/model/client_stream.go:324 - - app/server/model/client_stream.go:327 - - app/server/model/client_stream.go:330 - - app/server/model/client_stream.go:331 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/activate.go:29 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/build_exec.go:350 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Backoff patterns' - category: retry - description: Retry logic using backoff patterns - locations: - - app/server/model/plan/build_state.go:14 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/build_structured_edits.go:190 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/state.go:83 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/tell_exec.go:132 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Max retry configuration' - category: retry - description: Retry logic using max retry configuration - locations: - - app/server/model/plan/tell_stream_error.go:59 - - app/server/model/plan/tell_stream_error.go:61 - - app/server/model/plan/tell_stream_error.go:97 - - app/server/model/plan/tell_stream_error.go:127 - - app/server/model/plan/tell_stream_error.go:244 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Retry delay configuration' - category: retry - description: Retry logic using retry delay configuration - locations: - - app/server/model/plan/tell_stream_error.go:111 - - app/server/model/plan/tell_stream_error.go:114 - - app/server/model/plan/tell_stream_error.go:117 - - app/server/model/plan/tell_stream_error.go:127 - - app/server/model/plan/tell_stream_error.go:128 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/tell_stream_finish.go:52 - - app/server/model/plan/tell_stream_finish.go:54 - - app/server/model/plan/tell_stream_finish.go:233 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/tell_stream_processor.go:663 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Max retry configuration' - category: retry - description: Retry logic using max retry configuration - locations: - - app/server/syntax/file_map/examples/go_example.go:43 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/types/active_plan.go:271 - - app/server/types/active_plan.go:285 - - app/server/types/active_plan.go:307 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern -- name: 'Validation: Validation functions' - category: validation - description: Input validation via validation functions - locations: - - app/cli/cmd/plan_exec_helpers.go:131 - - app/cli/cmd/plan_exec_helpers.go:218 - - app/cli/schema/schemas.go:36 - - app/cli/schema/schemas.go:37 - - app/cli/schema/schemas.go:40 - - app/cli/schema/schemas.go:41 - - app/cli/schema/schemas.go:44 - - app/server/db/auth_helpers.go:33 - - app/server/db/auth_helpers.go:80 - - app/server/db/auth_helpers.go:81 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators -- name: 'Validation: Sanitization functions' - category: validation - description: Input validation via sanitization functions - locations: - - app/cli/url/url.go:70 - - app/cli/url/url.go:76 - - app/cli/url/url.go:77 - - app/cli/url/url.go:78 - - app/cli/url/url.go:79 - - app/cli/url/url.go:80 - - app/cli/url/url.go:81 - - app/cli/url/url.go:82 - - app/cli/url/url.go:83 - - app/cli/url/url.go:84 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators -- name: 'Validation: Empty string checks' - category: validation - description: Input validation via empty string checks - locations: - - app/cli/api/clients.go:26 - - app/cli/api/methods.go:1259 - - app/cli/api/methods.go:1291 - - app/cli/api/methods.go:1662 - - app/cli/auth/auth.go:58 - - app/cli/auth/auth.go:73 - - app/cli/auth/auth.go:104 - - app/cli/cmd/apply.go:45 - - app/cli/cmd/archive.go:54 - - app/cli/cmd/branches.go:33 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators -- name: 'Validation: String trimming' - category: validation - description: Input validation via string trimming - locations: - - app/cli/upgrade.go:60 - - app/cli/api/errors.go:20 - - app/cli/api/errors.go:30 - - app/cli/cmd/archive.go:36 - - app/cli/cmd/cd.go:37 - - app/cli/cmd/checkout.go:50 - - app/cli/cmd/delete_branch.go:40 - - app/cli/cmd/delete_plan.go:91 - - app/cli/cmd/repl.go:316 - - app/cli/cmd/repl.go:319 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators -- name: 'Validation: Regex validation' - category: validation - description: Input validation via regex validation - locations: - - app/cli/cmd/convo.go:178 - - app/cli/cmd/repl.go:488 - - app/cli/cmd/rewind.go:91 - - app/cli/cmd/rewind.go:503 - - app/cli/url/url.go:72 - - app/server/model/model_error.go:25 - - app/server/model/model_error.go:28 - - app/server/model/model_error.go:34 - - app/server/model/plan/tell_context.go:368 - - app/server/model/plan/tell_stream_processor.go:22 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators -- name: 'Validation: Validation errors' - category: validation - description: Input validation via validation errors - locations: - - app/server/db/auth_helpers.go:38 - - app/server/db/auth_helpers.go:51 - - app/server/model/prompts/explanation_format.go:456 - - app/server/model/prompts/explanation_format.go:482 - - app/server/model/prompts/explanation_format.go:680 - - app/server/model/prompts/explanation_format.go:709 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators -- name: 'Concurrency: Anonymous goroutines' - category: concurrency - description: Concurrent execution via anonymous goroutines - locations: - - app/cli/api/stream.go:24 - - app/cli/cmd/connect.go:52 - - app/cli/cmd/debug.go:109 - - app/cli/cmd/debug.go:161 - - app/cli/cmd/diffs.go:119 - - app/cli/cmd/models.go:103 - - app/cli/cmd/models.go:113 - - app/cli/cmd/new.go:50 - - app/cli/cmd/new.go:60 - - app/cli/cmd/plans.go:61 - triggers: [] - timing: null - concurrency: Go anonymous goroutines - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks -- name: 'Concurrency: Named goroutine calls' - category: concurrency - description: Concurrent execution via named goroutine calls - locations: - - app/cli/api/stream.go:24 - - app/cli/cmd/connect.go:52 - - app/cli/cmd/debug.go:109 - - app/cli/cmd/debug.go:161 - - app/cli/cmd/diffs.go:119 - - app/cli/cmd/models.go:103 - - app/cli/cmd/models.go:113 - - app/cli/cmd/new.go:50 - - app/cli/cmd/new.go:60 - - app/cli/cmd/plans.go:61 - triggers: [] - timing: null - concurrency: Go named goroutine calls - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks -- name: 'Concurrency: Channel declarations' - category: concurrency - description: Concurrent execution via channel declarations - locations: - - app/cli/cmd/browser.go:168 - - app/cli/cmd/browser.go:171 - - app/cli/cmd/debug.go:105 - - app/cli/cmd/models.go:101 - - app/cli/cmd/new.go:45 - - app/cli/cmd/plans.go:56 - - app/cli/cmd/revoke.go:35 - - app/cli/cmd/set_model.go:159 - - app/cli/cmd/tell.go:224 - - app/cli/cmd/users.go:33 - triggers: [] - timing: null - concurrency: Go channel declarations - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks -- name: 'Concurrency: Select statements' - category: concurrency - description: Concurrent execution via select statements - locations: - - app/cli/api/stream.go:26 - - app/cli/cmd/browser.go:225 - - app/cli/cmd/connect.go:66 - - app/cli/cmd/debug.go:112 - - app/cli/cmd/debug.go:140 - - app/cli/cmd/reject.go:127 - - app/cli/fs/projects.go:73 - - app/cli/term/select.go:13 - - app/server/db/convo_helpers.go:68 - - app/server/db/locks.go:80 - triggers: [] - timing: null - concurrency: Go select statements - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks -- name: 'Concurrency: Channel receive' - category: concurrency - description: Concurrent execution via channel receive - locations: - - app/cli/api/stream.go:27 - - app/cli/cmd/browser.go:226 - - app/cli/cmd/browser.go:229 - - app/cli/cmd/browser.go:232 - - app/cli/cmd/debug.go:113 - - app/cli/cmd/debug.go:141 - - app/cli/cmd/debug.go:147 - - app/cli/cmd/debug.go:152 - - app/cli/cmd/models.go:124 - - app/cli/cmd/new.go:71 - triggers: [] - timing: null - concurrency: Go channel receive - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks -- name: 'Concurrency: Channel send' - category: concurrency - description: Concurrent execution via channel send - locations: - - app/cli/api/stream.go:27 - - app/cli/cmd/browser.go:194 - - app/cli/cmd/browser.go:202 - - app/cli/cmd/browser.go:226 - - app/cli/cmd/browser.go:229 - - app/cli/cmd/browser.go:232 - - app/cli/cmd/debug.go:141 - - app/cli/cmd/debug.go:147 - - app/cli/cmd/debug.go:152 - - app/cli/cmd/models.go:107 - triggers: [] - timing: null - concurrency: Go channel send - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks -- name: 'Concurrency: WaitGroup usage' - category: concurrency - description: Concurrent execution via waitgroup usage - locations: - - app/cli/cmd/debug.go:103 - - app/cli/stream_tui/run.go:18 - - app/server/db/queue.go:227 - - app/server/handlers/file_maps_queue.go:84 - - app/server/syntax/file_map/examples/go_example.go:153 - triggers: [] - timing: null - concurrency: Go waitgroup usage - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks -- name: 'Streaming: Stream operations' - category: streaming - description: Real-time data streaming via stream operations - locations: - - app/cli/cmd/connect.go:45 - - app/cli/plan_exec/build.go:56 - - app/cli/plan_exec/tell.go:151 - - app/server/db/stream_helpers.go:38 - - app/server/db/stream_helpers.go:39 - - app/server/db/stream_helpers.go:56 - - app/server/db/stream_helpers.go:58 - - app/server/db/stream_helpers.go:63 - - app/server/db/stream_helpers.go:111 - - app/server/db/stream_helpers.go:112 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming -- name: 'Streaming: Server-sent events' - category: streaming - description: Real-time data streaming via server-sent events - locations: - - app/cli/api/stream.go:16 - - app/cli/cmd/browser.go:89 - - app/cli/cmd/debug.go:123 - - app/cli/cmd/plan_exec_helpers.go:113 - - app/cli/cmd/plan_exec_helpers.go:118 - - app/cli/cmd/rewind.go:27 - - app/cli/cmd/rewind.go:28 - - app/cli/cmd/rewind.go:29 - - app/cli/cmd/rewind.go:48 - - app/cli/cmd/rewind.go:49 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming -- name: 'Streaming: Stream copying' - category: streaming - description: Real-time data streaming via stream copying - locations: - - app/cli/upgrade.go:118 - - app/server/handlers/proxy_helper.go:102 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming -- name: 'Streaming: Buffered I/O' - category: streaming - description: Real-time data streaming via buffered i/o - locations: - - app/cli/api/stream.go:20 - - app/cli/api/stream.go:72 - - app/cli/cmd/debug.go:160 - - app/cli/cmd/tell.go:123 - - app/server/diff/diff.go:74 - - app/server/model/client.go:91 - - app/server/model/client.go:386 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming -- name: 'Streaming: Stream flushing' - category: streaming - description: Real-time data streaming via stream flushing - locations: - - app/server/handlers/stream_helper.go:122 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming -- name: 'Telemetry: Metrics collection' - category: telemetry - description: Usage tracking via metrics collection - locations: - - app/server/syntax/structured_edits_test.go:123 - - app/server/syntax/structured_edits_test.go:150 - triggers: - - Command execution - - Feature usage - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly -- name: 'Telemetry: Tracking functions' - category: telemetry - description: Usage tracking via tracking functions - locations: - - app/cli/fs/paths.go:91 - - app/cli/fs/paths.go:130 - - app/cli/fs/paths.go:138 - - app/cli/fs/paths.go:180 - - app/server/db/git.go:372 - - app/server/db/git.go:373 - - app/server/db/git.go:376 - - app/server/db/git.go:378 - - app/server/db/git.go:689 - - app/server/types/message.go:265 - triggers: - - Command execution - - Feature usage - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly -- name: 'Telemetry: Usage tracking' - category: telemetry - description: Usage tracking via usage tracking - locations: - - app/server/model/model_request.go:204 - - app/server/model/model_request.go:205 - - app/server/model/model_request.go:207 - - app/server/model/model_request.go:208 - - app/server/model/summarize.go:88 - - app/server/model/plan/tell_stream_usage.go:23 - - app/server/model/plan/tell_stream_usage.go:24 - - app/server/model/plan/tell_stream_usage.go:44 - - app/server/model/plan/tell_stream_usage.go:45 - triggers: - - Command execution - - Feature usage - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly -by_category: - auto-context: - - name: 'Auto-Context: Auto-load context configuration' - category: auto-context - description: Automatic context loading based on auto-load context configuration - locations: - - app/cli/api/methods.go:2386 - - app/cli/cmd/ls.go:96 - - app/cli/cmd/new.go:104 - - app/cli/cmd/new.go:128 - - app/cli/cmd/plan_exec_helpers.go:187 - - app/cli/cmd/plan_start_helpers.go:218 - - app/cli/cmd/repl.go:833 - - app/cli/cmd/set_config.go:333 - - app/cli/cmd/set_config.go:356 - - app/cli/stream_tui/model.go:84 - triggers: - - CLI command execution - - '@ symbol in input' - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use Python decorators for auto-loading - - Consider asyncio for concurrent context loads - - name: 'Auto-Context: At-symbol context references' - category: auto-context - description: Automatic context loading based on at-symbol context references - locations: - - app/cli/auth/account.go:189 - - app/cli/auth/trial.go:38 - - app/cli/auth/trial.go:86 - triggers: - - CLI command execution - - '@ symbol in input' - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use Python decorators for auto-loading - - Consider asyncio for concurrent context loads - locking: - - name: 'Locking: Explicit lock acquisition' - category: locking - description: Resource locking via explicit lock acquisition - locations: - - app/server/db/context_helpers_get.go:46 - - app/server/db/context_helpers_get.go:47 - - app/server/db/context_helpers_load.go:337 - - app/server/db/context_helpers_load.go:342 - - app/server/db/context_helpers_update.go:163 - - app/server/db/context_helpers_update.go:164 - - app/server/db/context_helpers_update.go:316 - - app/server/db/context_helpers_update.go:325 - - app/server/db/locks.go:381 - - app/server/db/locks.go:383 - - app/server/db/locks.go:516 - - app/server/db/locks.go:518 - - app/server/db/locks.go:662 - - app/server/db/locks.go:664 - - app/server/db/queue.go:43 - - app/server/db/queue.go:44 - - app/server/db/queue.go:72 - - app/server/db/queue.go:90 - - app/server/db/queue.go:96 - - app/server/db/queue.go:97 - - app/server/db/queue.go:163 - - app/server/db/queue.go:165 - - app/server/db/result_helpers.go:1070 - - app/server/db/result_helpers.go:1072 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - - name: 'Locking: Lock release' - category: locking - description: Resource locking via lock release - locations: - - app/server/db/context_helpers_get.go:47 - - app/server/db/context_helpers_load.go:342 - - app/server/db/context_helpers_update.go:164 - - app/server/db/context_helpers_update.go:325 - - app/server/db/locks.go:383 - - app/server/db/locks.go:518 - - app/server/db/locks.go:664 - - app/server/db/queue.go:44 - - app/server/db/queue.go:90 - - app/server/db/queue.go:97 - - app/server/db/queue.go:165 - - app/server/db/result_helpers.go:1072 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - - name: 'Locking: Mutex usage' - category: locking - description: Resource locking via mutex usage - locations: - - app/server/db/context_helpers_get.go:31 - - app/server/db/context_helpers_load.go:288 - - app/server/db/context_helpers_update.go:137 - - app/server/db/locks.go:39 - - app/server/db/queue.go:33 - - app/server/db/queue.go:39 - - app/server/db/result_helpers.go:1042 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - - name: 'Locking: File-based locking' - category: locking - description: Resource locking via file-based locking - locations: - - app/server/db/git.go:404 - - app/server/db/git.go:416 - - app/server/db/git.go:430 - - app/server/db/git.go:557 - - app/server/db/git.go:558 - - app/server/db/git.go:571 - - app/server/db/git.go:573 - - app/server/db/git.go:575 - - app/server/db/git.go:582 - - app/server/db/git.go:589 - - app/server/db/git.go:591 - - app/server/db/git.go:593 - - app/server/db/git.go:604 - - app/server/db/git.go:605 - - app/server/db/git.go:619 - - app/server/db/git.go:620 - - app/server/db/git.go:624 - - app/server/db/git.go:673 - - app/server/db/locks.go:461 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - - name: 'Locking: Deferred unlock patterns' - category: locking - description: Resource locking via deferred unlock patterns - locations: - - app/server/db/context_helpers_get.go:47 - - app/server/db/context_helpers_update.go:164 - - app/server/db/queue.go:44 - - app/server/db/queue.go:97 - triggers: [] - timing: null - concurrency: Go mutexes/file locks - failure_handling: Deferred unlock ensures cleanup - python_considerations: - - Use threading.Lock or asyncio.Lock - - Consider fcntl for file locks - - Use context managers for automatic cleanup - retry: - - name: 'Retry: Manual retry loops' - category: retry - description: Retry logic using manual retry loops - locations: - - app/cli/api/clients.go:82 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Backoff patterns' - category: retry - description: Retry logic using backoff patterns - locations: - - app/cli/api/clients.go:108 - - app/cli/api/clients.go:109 - - app/cli/api/clients.go:110 - - app/cli/api/clients.go:111 - - app/cli/api/clients.go:113 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Max retry configuration' - category: retry - description: Retry logic using max retry configuration - locations: - - app/cli/api/clients.go:68 - - app/cli/api/clients.go:82 - - app/cli/api/clients.go:104 - - app/cli/api/clients.go:129 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/auth/trial.go:34 - - app/cli/auth/trial.go:82 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/cmd/cd.go:113 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Manual retry loops' - category: retry - description: Retry logic using manual retry loops - locations: - - app/cli/cmd/debug.go:78 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/cmd/tell.go:252 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/plan_exec/tell.go:239 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/stream_tui/update.go:569 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/cli/term/spinner.go:66 - - app/cli/term/spinner.go:72 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Manual retry loops' - category: retry - description: Retry logic using manual retry loops - locations: - - app/server/db/git.go:658 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/db/git.go:598 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Backoff patterns' - category: retry - description: Retry logic using backoff patterns - locations: - - app/server/db/git.go:660 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Retry delay configuration' - category: retry - description: Retry logic using retry delay configuration - locations: - - app/server/db/git.go:21 - - app/server/db/git.go:660 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Backoff patterns' - category: retry - description: Retry logic using backoff patterns - locations: - - app/server/db/locks.go:31 - - app/server/db/locks.go:32 - - app/server/db/locks.go:34 - - app/server/db/locks.go:163 - - app/server/db/locks.go:185 - - app/server/db/locks.go:287 - - app/server/db/locks.go:344 - - app/server/db/locks.go:345 - - app/server/db/locks.go:364 - - app/server/db/locks.go:564 - - app/server/db/locks.go:577 - - app/server/db/locks.go:579 - - app/server/db/locks.go:582 - - app/server/db/locks.go:604 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Retry delay configuration' - category: retry - description: Retry logic using retry delay configuration - locations: - - app/server/db/locks.go:30 - - app/server/db/locks.go:36 - - app/server/db/locks.go:576 - - app/server/db/locks.go:577 - - app/server/db/locks.go:608 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/handlers/plans_changes.go:39 - - app/server/handlers/plans_changes.go:143 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/handlers/plans_exec.go:296 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/handlers/stream_helper.go:53 - - app/server/handlers/stream_helper.go:69 - - app/server/handlers/stream_helper.go:71 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Max retry configuration' - category: retry - description: Retry logic using max retry configuration - locations: - - app/server/model/client_stream.go:277 - - app/server/model/client_stream.go:279 - - app/server/model/client_stream.go:291 - - app/server/model/client_stream.go:316 - - app/server/model/client_stream.go:317 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Retry delay configuration' - category: retry - description: Retry logic using retry delay configuration - locations: - - app/server/model/client_stream.go:321 - - app/server/model/client_stream.go:324 - - app/server/model/client_stream.go:327 - - app/server/model/client_stream.go:330 - - app/server/model/client_stream.go:331 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/activate.go:29 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/build_exec.go:350 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Backoff patterns' - category: retry - description: Retry logic using backoff patterns - locations: - - app/server/model/plan/build_state.go:14 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/build_structured_edits.go:190 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/state.go:83 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/tell_exec.go:132 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Max retry configuration' - category: retry - description: Retry logic using max retry configuration - locations: - - app/server/model/plan/tell_stream_error.go:59 - - app/server/model/plan/tell_stream_error.go:61 - - app/server/model/plan/tell_stream_error.go:97 - - app/server/model/plan/tell_stream_error.go:127 - - app/server/model/plan/tell_stream_error.go:244 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Retry delay configuration' - category: retry - description: Retry logic using retry delay configuration - locations: - - app/server/model/plan/tell_stream_error.go:111 - - app/server/model/plan/tell_stream_error.go:114 - - app/server/model/plan/tell_stream_error.go:117 - - app/server/model/plan/tell_stream_error.go:127 - - app/server/model/plan/tell_stream_error.go:128 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/tell_stream_finish.go:52 - - app/server/model/plan/tell_stream_finish.go:54 - - app/server/model/plan/tell_stream_finish.go:233 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/model/plan/tell_stream_processor.go:663 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Max retry configuration' - category: retry - description: Retry logic using max retry configuration - locations: - - app/server/syntax/file_map/examples/go_example.go:43 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - - name: 'Retry: Exponential backoff' - category: retry - description: Retry logic using exponential backoff - locations: - - app/server/types/active_plan.go:271 - - app/server/types/active_plan.go:285 - - app/server/types/active_plan.go:307 - triggers: [] - timing: Exponential backoff common - concurrency: null - failure_handling: Max attempts then fail - python_considerations: - - Use tenacity or backoff libraries - - Consider asyncio.wait_for for timeouts - - Implement circuit breaker pattern - validation: - - name: 'Validation: Validation functions' - category: validation - description: Input validation via validation functions - locations: - - app/cli/cmd/plan_exec_helpers.go:131 - - app/cli/cmd/plan_exec_helpers.go:218 - - app/cli/schema/schemas.go:36 - - app/cli/schema/schemas.go:37 - - app/cli/schema/schemas.go:40 - - app/cli/schema/schemas.go:41 - - app/cli/schema/schemas.go:44 - - app/server/db/auth_helpers.go:33 - - app/server/db/auth_helpers.go:80 - - app/server/db/auth_helpers.go:81 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - - name: 'Validation: Sanitization functions' - category: validation - description: Input validation via sanitization functions - locations: - - app/cli/url/url.go:70 - - app/cli/url/url.go:76 - - app/cli/url/url.go:77 - - app/cli/url/url.go:78 - - app/cli/url/url.go:79 - - app/cli/url/url.go:80 - - app/cli/url/url.go:81 - - app/cli/url/url.go:82 - - app/cli/url/url.go:83 - - app/cli/url/url.go:84 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - - name: 'Validation: Empty string checks' - category: validation - description: Input validation via empty string checks - locations: - - app/cli/api/clients.go:26 - - app/cli/api/methods.go:1259 - - app/cli/api/methods.go:1291 - - app/cli/api/methods.go:1662 - - app/cli/auth/auth.go:58 - - app/cli/auth/auth.go:73 - - app/cli/auth/auth.go:104 - - app/cli/cmd/apply.go:45 - - app/cli/cmd/archive.go:54 - - app/cli/cmd/branches.go:33 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - - name: 'Validation: String trimming' - category: validation - description: Input validation via string trimming - locations: - - app/cli/upgrade.go:60 - - app/cli/api/errors.go:20 - - app/cli/api/errors.go:30 - - app/cli/cmd/archive.go:36 - - app/cli/cmd/cd.go:37 - - app/cli/cmd/checkout.go:50 - - app/cli/cmd/delete_branch.go:40 - - app/cli/cmd/delete_plan.go:91 - - app/cli/cmd/repl.go:316 - - app/cli/cmd/repl.go:319 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - - name: 'Validation: Regex validation' - category: validation - description: Input validation via regex validation - locations: - - app/cli/cmd/convo.go:178 - - app/cli/cmd/repl.go:488 - - app/cli/cmd/rewind.go:91 - - app/cli/cmd/rewind.go:503 - - app/cli/url/url.go:72 - - app/server/model/model_error.go:25 - - app/server/model/model_error.go:28 - - app/server/model/model_error.go:34 - - app/server/model/plan/tell_context.go:368 - - app/server/model/plan/tell_stream_processor.go:22 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - - name: 'Validation: Validation errors' - category: validation - description: Input validation via validation errors - locations: - - app/server/db/auth_helpers.go:38 - - app/server/db/auth_helpers.go:51 - - app/server/model/prompts/explanation_format.go:456 - - app/server/model/prompts/explanation_format.go:482 - - app/server/model/prompts/explanation_format.go:680 - - app/server/model/prompts/explanation_format.go:709 - triggers: - - User input - - API requests - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Use pydantic for data validation - - Consider marshmallow for serialization - - Apply validators as decorators - concurrency: - - name: 'Concurrency: Anonymous goroutines' - category: concurrency - description: Concurrent execution via anonymous goroutines - locations: - - app/cli/api/stream.go:24 - - app/cli/cmd/connect.go:52 - - app/cli/cmd/debug.go:109 - - app/cli/cmd/debug.go:161 - - app/cli/cmd/diffs.go:119 - - app/cli/cmd/models.go:103 - - app/cli/cmd/models.go:113 - - app/cli/cmd/new.go:50 - - app/cli/cmd/new.go:60 - - app/cli/cmd/plans.go:61 - triggers: [] - timing: null - concurrency: Go anonymous goroutines - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - - name: 'Concurrency: Named goroutine calls' - category: concurrency - description: Concurrent execution via named goroutine calls - locations: - - app/cli/api/stream.go:24 - - app/cli/cmd/connect.go:52 - - app/cli/cmd/debug.go:109 - - app/cli/cmd/debug.go:161 - - app/cli/cmd/diffs.go:119 - - app/cli/cmd/models.go:103 - - app/cli/cmd/models.go:113 - - app/cli/cmd/new.go:50 - - app/cli/cmd/new.go:60 - - app/cli/cmd/plans.go:61 - triggers: [] - timing: null - concurrency: Go named goroutine calls - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - - name: 'Concurrency: Channel declarations' - category: concurrency - description: Concurrent execution via channel declarations - locations: - - app/cli/cmd/browser.go:168 - - app/cli/cmd/browser.go:171 - - app/cli/cmd/debug.go:105 - - app/cli/cmd/models.go:101 - - app/cli/cmd/new.go:45 - - app/cli/cmd/plans.go:56 - - app/cli/cmd/revoke.go:35 - - app/cli/cmd/set_model.go:159 - - app/cli/cmd/tell.go:224 - - app/cli/cmd/users.go:33 - triggers: [] - timing: null - concurrency: Go channel declarations - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - - name: 'Concurrency: Select statements' - category: concurrency - description: Concurrent execution via select statements - locations: - - app/cli/api/stream.go:26 - - app/cli/cmd/browser.go:225 - - app/cli/cmd/connect.go:66 - - app/cli/cmd/debug.go:112 - - app/cli/cmd/debug.go:140 - - app/cli/cmd/reject.go:127 - - app/cli/fs/projects.go:73 - - app/cli/term/select.go:13 - - app/server/db/convo_helpers.go:68 - - app/server/db/locks.go:80 - triggers: [] - timing: null - concurrency: Go select statements - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - - name: 'Concurrency: Channel receive' - category: concurrency - description: Concurrent execution via channel receive - locations: - - app/cli/api/stream.go:27 - - app/cli/cmd/browser.go:226 - - app/cli/cmd/browser.go:229 - - app/cli/cmd/browser.go:232 - - app/cli/cmd/debug.go:113 - - app/cli/cmd/debug.go:141 - - app/cli/cmd/debug.go:147 - - app/cli/cmd/debug.go:152 - - app/cli/cmd/models.go:124 - - app/cli/cmd/new.go:71 - triggers: [] - timing: null - concurrency: Go channel receive - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - - name: 'Concurrency: Channel send' - category: concurrency - description: Concurrent execution via channel send - locations: - - app/cli/api/stream.go:27 - - app/cli/cmd/browser.go:194 - - app/cli/cmd/browser.go:202 - - app/cli/cmd/browser.go:226 - - app/cli/cmd/browser.go:229 - - app/cli/cmd/browser.go:232 - - app/cli/cmd/debug.go:141 - - app/cli/cmd/debug.go:147 - - app/cli/cmd/debug.go:152 - - app/cli/cmd/models.go:107 - triggers: [] - timing: null - concurrency: Go channel send - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - - name: 'Concurrency: WaitGroup usage' - category: concurrency - description: Concurrent execution via waitgroup usage - locations: - - app/cli/cmd/debug.go:103 - - app/cli/stream_tui/run.go:18 - - app/server/db/queue.go:227 - - app/server/handlers/file_maps_queue.go:84 - - app/server/syntax/file_map/examples/go_example.go:153 - triggers: [] - timing: null - concurrency: Go waitgroup usage - failure_handling: null - python_considerations: - - Use asyncio tasks for coroutines - - Queue.Queue for channel-like behavior - - asyncio.gather for WaitGroup equivalent - - Consider threading for CPU-bound tasks - streaming: - - name: 'Streaming: Stream operations' - category: streaming - description: Real-time data streaming via stream operations - locations: - - app/cli/cmd/connect.go:45 - - app/cli/plan_exec/build.go:56 - - app/cli/plan_exec/tell.go:151 - - app/server/db/stream_helpers.go:38 - - app/server/db/stream_helpers.go:39 - - app/server/db/stream_helpers.go:56 - - app/server/db/stream_helpers.go:58 - - app/server/db/stream_helpers.go:63 - - app/server/db/stream_helpers.go:111 - - app/server/db/stream_helpers.go:112 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - - name: 'Streaming: Server-sent events' - category: streaming - description: Real-time data streaming via server-sent events - locations: - - app/cli/api/stream.go:16 - - app/cli/cmd/browser.go:89 - - app/cli/cmd/debug.go:123 - - app/cli/cmd/plan_exec_helpers.go:113 - - app/cli/cmd/plan_exec_helpers.go:118 - - app/cli/cmd/rewind.go:27 - - app/cli/cmd/rewind.go:28 - - app/cli/cmd/rewind.go:29 - - app/cli/cmd/rewind.go:48 - - app/cli/cmd/rewind.go:49 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - - name: 'Streaming: Stream copying' - category: streaming - description: Real-time data streaming via stream copying - locations: - - app/cli/upgrade.go:118 - - app/server/handlers/proxy_helper.go:102 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - - name: 'Streaming: Buffered I/O' - category: streaming - description: Real-time data streaming via buffered i/o - locations: - - app/cli/api/stream.go:20 - - app/cli/api/stream.go:72 - - app/cli/cmd/debug.go:160 - - app/cli/cmd/tell.go:123 - - app/server/diff/diff.go:74 - - app/server/model/client.go:91 - - app/server/model/client.go:386 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - - name: 'Streaming: Stream flushing' - category: streaming - description: Real-time data streaming via stream flushing - locations: - - app/server/handlers/stream_helper.go:122 - triggers: [] - timing: Real-time/low-latency - concurrency: null - failure_handling: null - python_considerations: - - Use aiohttp for WebSocket support - - Consider Server-Sent Events for unidirectional - - Implement proper backpressure handling - - Use async generators for streaming - telemetry: - - name: 'Telemetry: Metrics collection' - category: telemetry - description: Usage tracking via metrics collection - locations: - - app/server/syntax/structured_edits_test.go:123 - - app/server/syntax/structured_edits_test.go:150 - triggers: - - Command execution - - Feature usage - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly - - name: 'Telemetry: Tracking functions' - category: telemetry - description: Usage tracking via tracking functions - locations: - - app/cli/fs/paths.go:91 - - app/cli/fs/paths.go:130 - - app/cli/fs/paths.go:138 - - app/cli/fs/paths.go:180 - - app/server/db/git.go:372 - - app/server/db/git.go:373 - - app/server/db/git.go:376 - - app/server/db/git.go:378 - - app/server/db/git.go:689 - - app/server/types/message.go:265 - triggers: - - Command execution - - Feature usage - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly - - name: 'Telemetry: Usage tracking' - category: telemetry - description: Usage tracking via usage tracking - locations: - - app/server/model/model_request.go:204 - - app/server/model/model_request.go:205 - - app/server/model/model_request.go:207 - - app/server/model/model_request.go:208 - - app/server/model/summarize.go:88 - - app/server/model/plan/tell_stream_usage.go:23 - - app/server/model/plan/tell_stream_usage.go:24 - - app/server/model/plan/tell_stream_usage.go:44 - - app/server/model/plan/tell_stream_usage.go:45 - triggers: - - Command execution - - Feature usage - timing: null - concurrency: null - failure_handling: null - python_considerations: - - Make telemetry opt-in by default - - Use structured logging for metrics - - Consider OpenTelemetry for standards - - Respect privacy settings strictly -statistics: - total_behaviors: 61 - categories: - - auto-context - - locking - - retry - - validation - - concurrency - - streaming - - telemetry - behaviors_per_category: - auto-context: 2 - locking: 5 - retry: 33 - validation: 6 - concurrency: 7 - streaming: 5 - telemetry: 3 - python_migration_considerations: - - Apply validators as decorators - - Consider OpenTelemetry for standards - - Consider Server-Sent Events for unidirectional - - Consider asyncio for concurrent context loads - - Consider asyncio.wait_for for timeouts - - Consider fcntl for file locks - - Consider marshmallow for serialization - - Consider threading for CPU-bound tasks - - Implement circuit breaker pattern - - Implement proper backpressure handling - - Make telemetry opt-in by default - - Queue.Queue for channel-like behavior - - Respect privacy settings strictly - - Use Python decorators for auto-loading - - Use aiohttp for WebSocket support - - Use async generators for streaming - - Use asyncio tasks for coroutines - - Use context managers for automatic cleanup - - Use pydantic for data validation - - Use structured logging for metrics - - Use tenacity or backoff libraries - - Use threading.Lock or asyncio.Lock - - asyncio.gather for WaitGroup equivalent -sequence_diagrams: - auto_context_loading: 'User -> CLI: Execute command with @context - - CLI -> ContextLoader: Parse @ reference - - ContextLoader -> FileSystem: Load context file - - FileSystem -> ContextLoader: Return content - - ContextLoader -> CLI: Inject context - - CLI -> Server: Execute with context' - retry_with_backoff: 'Client -> Service: Make request - - Service -> Provider: Call API - - Provider -> Service: Error/Timeout - - Service -> Service: Wait (exponential backoff) - - Service -> Provider: Retry request - - Provider -> Service: Success - - Service -> Client: Return result' - git_locking: 'CLI -> LockManager: Acquire git lock - - LockManager -> FileSystem: Create lock file - - FileSystem -> LockManager: Lock acquired - - LockManager -> CLI: Proceed - - CLI -> Git: Execute operations - - Git -> CLI: Complete - - CLI -> LockManager: Release lock - - LockManager -> FileSystem: Remove lock file' diff --git a/docs/reference/cli_inventory.json b/docs/reference/cli_inventory.json deleted file mode 100644 index 080874107..000000000 --- a/docs/reference/cli_inventory.json +++ /dev/null @@ -1,1353 +0,0 @@ -{ - "root": { - "name": "root", - "use": "plandex [command] [flags]", - "aliases": [], - "short_description": "Plandex: iterative development with AI", - "long_description": "", - "flags": [], - "subcommands": [ - "helpCmd", - "connectClaudeCmd", - "disconnectClaudeCmd" - ], - "parent": null, - "run_function": "func", - "file_path": "/app/plandex/app/cli/cmd/root.go", - "requires_auth": false, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "commands": { - "apply": { - "name": "apply", - "use": "apply", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/apply.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "archive": { - "name": "archive", - "use": "archive [name-or-index]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/archive.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": false, - "hidden": false - }, - "billing": { - "name": "billing", - "use": "billing", - "aliases": [], - "short_description": "Open the billing page in the browser", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "billing", - "file_path": "/app/plandex/app/cli/cmd/billing.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "branches": { - "name": "branches", - "use": "branches", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/branches.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "browser": { - "name": "browser", - "use": "browser [urls...]", - "aliases": [], - "short_description": "Open browser windows with given URLs, capturing console logs and exiting on JS errors", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/browser.go", - "requires_auth": false, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "build": { - "name": "build", - "use": "build", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/build.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "cd": { - "name": "cd", - "use": "cd [name-or-index]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/cd.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": false, - "hidden": false - }, - "chat": { - "name": "chat", - "use": "chat [prompt]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/chat.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "checkout": { - "name": "checkout", - "use": "checkout [name-or-index]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "yes", - "shorthand": "y", - "flag_type": "bool", - "default_value": false, - "description": "Confirm creating a new branch", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/checkout.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "connect-claude": { - "name": "connect-claude", - "use": "connect-claude", - "aliases": [], - "short_description": "Connect your Claude Pro or Max subscription", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": "root", - "run_function": "connectClaude", - "file_path": "/app/plandex/app/cli/cmd/claude_max.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "disconnect-claude": { - "name": "disconnect-claude", - "use": "disconnect-claude", - "aliases": [], - "short_description": "Disconnect your Claude Pro or Max subscription", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": "root", - "run_function": "disconnectClaude", - "file_path": "/app/plandex/app/cli/cmd/claude_max.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "claude-status": { - "name": "claude-status", - "use": "claude-status", - "aliases": [], - "short_description": "Check the status of your Claude Pro or Max subscription", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "claudeStatus", - "file_path": "/app/plandex/app/cli/cmd/claude_max.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "clear": { - "name": "clear", - "use": "clear", - "aliases": [], - "short_description": "Clear all context", - "long_description": "Clear all context.", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "clearAllContext", - "file_path": "/app/plandex/app/cli/cmd/clear.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "config": { - "name": "config", - "use": "config", - "aliases": [], - "short_description": "Show plan config", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "config", - "file_path": "/app/plandex/app/cli/cmd/config.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "default-config": { - "name": "default-config", - "use": "default", - "aliases": [], - "short_description": "Show default config for new plans", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "defaultConfig", - "file_path": "/app/plandex/app/cli/cmd/config.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "connect": { - "name": "connect", - "use": "connect [stream-id-or-plan] [branch]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/connect.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "context-show": { - "name": "context-show", - "use": "show [name-or-index]", - "aliases": [], - "short_description": "Show the body of a context by name or list index", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/context_show.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "continue": { - "name": "continue", - "use": "continue", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/continue.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "convo": { - "name": "convo", - "use": "convo [msg-range]", - "aliases": [], - "short_description": "Display complete conversation history", - "long_description": "Display complete conversation history. Optionally specify a message number or range of messages (e.g. '1' or '5' or '1-5' or '5-')", - "flags": [ - { - "name": "plain", - "shorthand": "p", - "flag_type": "bool", - "default_value": false, - "description": "Output conversation in plain text with no ANSI codes", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": "convo", - "file_path": "/app/plandex/app/cli/cmd/convo.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "current": { - "name": "current", - "use": "current", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/current.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": true, - "hidden": false - }, - "debug": { - "name": "debug", - "use": "debug [tries] ", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "commit", - "shorthand": "c", - "flag_type": "bool", - "default_value": false, - "description": "Commit changes after successful execution", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/debug.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "delete-branch": { - "name": "delete-branch", - "use": "delete-branch", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/delete_branch.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "rm": { - "name": "rm", - "use": "delete-plan [name-or-index]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/delete_plan.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "diffs": { - "name": "diffs", - "use": "diff", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "plain", - "shorthand": "p", - "flag_type": "bool", - "default_value": false, - "description": "Output diffs in plain text with no ANSI codes", - "required": false, - "global_flag": false - }, - { - "name": "side", - "shorthand": "s", - "flag_type": "bool", - "default_value": true, - "description": "Show diffs UI in side-by-side view", - "required": false, - "global_flag": false - }, - { - "name": "line", - "shorthand": "l", - "flag_type": "bool", - "default_value": false, - "description": "Show diffs UI in line-by-line view", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/diffs.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": true, - "hidden": false - }, - "invite": { - "name": "invite", - "use": "invite [email] [name] [org-role]", - "aliases": [], - "short_description": "Invite a new user to the org", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "invite", - "file_path": "/app/plandex/app/cli/cmd/invite.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "context-load": { - "name": "context-load", - "use": "load [files-or-urls...]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "recursive", - "shorthand": "r", - "flag_type": "bool", - "default_value": false, - "description": "Search directories recursively", - "required": false, - "global_flag": false - }, - { - "name": "force", - "shorthand": "f", - "flag_type": "bool", - "default_value": false, - "description": "Load files even when ignored by .gitignore or .plandexignore", - "required": false, - "global_flag": false - }, - { - "name": "note", - "shorthand": "n", - "flag_type": "string", - "default_value": "", - "description": "Add a note to the context", - "required": false, - "global_flag": false - }, - { - "name": "detail", - "shorthand": "d", - "flag_type": "string", - "default_value": "high", - "description": "Image detail level (high or low)", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/load.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "log": { - "name": "log", - "use": "log", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/log.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "context": { - "name": "context", - "use": "ls", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/ls.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "model-packs": { - "name": "model-packs", - "use": "model-packs", - "aliases": [], - "short_description": "List all model packs", - "long_description": "", - "flags": [ - { - "name": "custom", - "shorthand": "c", - "flag_type": "bool", - "default_value": false, - "description": "Only show custom model packs", - "required": false, - "global_flag": false - }, - { - "name": "all", - "shorthand": "a", - "flag_type": "bool", - "default_value": false, - "description": "Show all properties", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": "listModelPacks", - "file_path": "/app/plandex/app/cli/cmd/model_packs.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "create-model-pack": { - "name": "create-model-pack", - "use": "create", - "aliases": [], - "short_description": "Create a model pack", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "customModelsNotImplemented", - "file_path": "/app/plandex/app/cli/cmd/model_packs.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "delete-model-pack": { - "name": "delete-model-pack", - "use": "delete", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/model_packs.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "update-model-pack": { - "name": "update-model-pack", - "use": "update", - "aliases": [], - "short_description": "Update a model pack by name", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "customModelsNotImplemented", - "file_path": "/app/plandex/app/cli/cmd/model_packs.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "show-model-pack": { - "name": "show-model-pack", - "use": "show [name]", - "aliases": [], - "short_description": "Show a model pack by name", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "showModelPack", - "file_path": "/app/plandex/app/cli/cmd/model_packs.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "providers": { - "name": "providers", - "use": "providers", - "aliases": [], - "short_description": "List built-in and custom model providers", - "long_description": "", - "flags": [ - { - "name": "custom", - "shorthand": "c", - "flag_type": "bool", - "default_value": false, - "description": "List custom providers only", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": "listProviders", - "file_path": "/app/plandex/app/cli/cmd/model_providers.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "add-provider": { - "name": "add-provider", - "use": "add", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/model_providers.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "update-provider": { - "name": "update-provider", - "use": "update", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/model_providers.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "models": { - "name": "models", - "use": "models", - "aliases": [], - "short_description": "Show plan model settings", - "long_description": "", - "flags": [ - { - "name": "all", - "shorthand": "a", - "flag_type": "bool", - "default_value": false, - "description": "Show all properties", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": "models", - "file_path": "/app/plandex/app/cli/cmd/models.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "default-models": { - "name": "default-models", - "use": "default", - "aliases": [], - "short_description": "Show default model settings for new plans", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "defaultModels", - "file_path": "/app/plandex/app/cli/cmd/models.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "list-available-models": { - "name": "list-available-models", - "use": "available", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "custom", - "shorthand": "c", - "flag_type": "bool", - "default_value": false, - "description": "List custom models only", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/models.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "manage-custom-models": { - "name": "manage-custom-models", - "use": "custom", - "aliases": [], - "short_description": "Manage custom models, providers, and model packs", - "long_description": "", - "flags": [ - { - "name": "file", - "shorthand": "f", - "flag_type": "string", - "default_value": "", - "description": "Path to custom models file", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": "manageCustomModels", - "file_path": "/app/plandex/app/cli/cmd/models.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "add-custom-model": { - "name": "add-custom-model", - "use": "add", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/models.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "update-custom-model": { - "name": "update-custom-model", - "use": "update", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/models.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "delete-custom-model": { - "name": "delete-custom-model", - "use": "rm", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/models.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "new": { - "name": "new", - "use": "new", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "name", - "shorthand": "n", - "flag_type": "string", - "default_value": "", - "description": "Name of the new plan", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/new.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "plans": { - "name": "plans", - "use": "plans", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "archived", - "shorthand": "a", - "flag_type": "bool", - "default_value": false, - "description": "List archived plans", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/plans.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": true, - "hidden": false - }, - "ps": { - "name": "ps", - "use": "ps", - "aliases": [], - "short_description": "List plans with active or recently finished streams", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "ps", - "file_path": "/app/plandex/app/cli/cmd/ps.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "reject": { - "name": "reject", - "use": "reject [files...]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "all", - "shorthand": "a", - "flag_type": "bool", - "default_value": false, - "description": "Reject all pending changes", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/reject.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "rename": { - "name": "rename", - "use": "rename [new-name]", - "aliases": [], - "short_description": "Rename the current plan", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "rename", - "file_path": "/app/plandex/app/cli/cmd/rename.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "repl": { - "name": "repl", - "use": "repl", - "aliases": [], - "short_description": "Start interactive Plandex REPL", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "runRepl", - "file_path": "/app/plandex/app/cli/cmd/repl.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": true, - "hidden": false - }, - "revoke": { - "name": "revoke", - "use": "revoke [email]", - "aliases": [], - "short_description": "Revoke an invite or remove a user from the org", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "revoke", - "file_path": "/app/plandex/app/cli/cmd/revoke.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "rewind": { - "name": "rewind", - "use": "rewind [steps-or-sha]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/rewind.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "context-rm": { - "name": "context-rm", - "use": "rm", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/rm.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "set-config": { - "name": "set-config", - "use": "set-config [setting] [value]", - "aliases": [], - "short_description": "Update current plan config", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "setConfig", - "file_path": "/app/plandex/app/cli/cmd/set_config.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "default-set-config": { - "name": "default-set-config", - "use": "default [setting] [value]", - "aliases": [], - "short_description": "Update default plan config", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "defaultSetConfig", - "file_path": "/app/plandex/app/cli/cmd/set_config.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "set-auto": { - "name": "set-auto", - "use": "set-auto [value]", - "aliases": [], - "short_description": "Update config auto-mode", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "setAuto", - "file_path": "/app/plandex/app/cli/cmd/set_config.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "set-auto-default": { - "name": "set-auto-default", - "use": "default [value]", - "aliases": [], - "short_description": "Update default config auto-mode", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "setAutoDefault", - "file_path": "/app/plandex/app/cli/cmd/set_config.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "models-set": { - "name": "models-set", - "use": "set-model [model-pack-name]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [ - { - "name": "file", - "shorthand": "f", - "flag_type": "string", - "default_value": "", - "description": "Path to model settings JSON file", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/set_model.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "default-model-set": { - "name": "default-model-set", - "use": "default [model-pack-name]", - "aliases": [], - "short_description": "Update org-wide default model settings", - "long_description": "", - "flags": [ - { - "name": "file", - "shorthand": "f", - "flag_type": "string", - "default_value": "", - "description": "Path to model settings JSON file", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": "defaultModelsSet", - "file_path": "/app/plandex/app/cli/cmd/set_model.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "sign-in": { - "name": "sign-in", - "use": "sign-in", - "aliases": [], - "short_description": "Sign in to a Plandex account", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "signIn", - "file_path": "/app/plandex/app/cli/cmd/sign_in.go", - "requires_auth": false, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "stop": { - "name": "stop", - "use": "stop [stream-id-or-plan] [branch]", - "aliases": [], - "short_description": "Connect to an active stream", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "stop", - "file_path": "/app/plandex/app/cli/cmd/stop.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "status": { - "name": "status", - "use": "summary", - "aliases": [], - "short_description": "Show the latest summary of the current plan", - "long_description": "", - "flags": [ - { - "name": "plain", - "shorthand": "p", - "flag_type": "bool", - "default_value": false, - "description": "Output summary in plain text with no ANSI codes", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": "status", - "file_path": "/app/plandex/app/cli/cmd/summary.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "tell": { - "name": "tell", - "use": "tell [prompt]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/tell.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "unarchive": { - "name": "unarchive", - "use": "unarchive [name-or-index]", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/unarchive.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": false, - "hidden": false - }, - "update": { - "name": "update", - "use": "update", - "aliases": [], - "short_description": "", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": null, - "file_path": "/app/plandex/app/cli/cmd/update.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "usage": { - "name": "usage", - "use": "usage", - "aliases": [], - "short_description": "Display credits balance and usage report", - "long_description": "", - "flags": [ - { - "name": "page-size", - "shorthand": "s", - "flag_type": "int", - "default_value": 100, - "description": "Number of transactions to display per page", - "required": false, - "global_flag": false - }, - { - "name": "page", - "shorthand": "p", - "flag_type": "int", - "default_value": 1, - "description": "Page number to display", - "required": false, - "global_flag": false - } - ], - "subcommands": [], - "parent": null, - "run_function": "usage", - "file_path": "/app/plandex/app/cli/cmd/usage.go", - "requires_auth": true, - "requires_project": true, - "requires_plan": true, - "hidden": false - }, - "users": { - "name": "users", - "use": "users", - "aliases": [], - "short_description": "List all users and pending invites and the current org", - "long_description": "", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "listUsersAndInvites", - "file_path": "/app/plandex/app/cli/cmd/users.go", - "requires_auth": true, - "requires_project": false, - "requires_plan": false, - "hidden": false - }, - "version": { - "name": "version", - "use": "version", - "aliases": [], - "short_description": "Print the version number of Plandex", - "long_description": "All software has versions. This is Plandex's", - "flags": [], - "subcommands": [], - "parent": null, - "run_function": "func", - "file_path": "/app/plandex/app/cli/cmd/version.go", - "requires_auth": false, - "requires_project": false, - "requires_plan": false, - "hidden": false - } - }, - "hierarchy": { - "root": { - "subcommands": [ - "connect-claude", - "disconnect-claude" - ] - } - }, - "metadata": { - "repl_commands": [], - "shortcuts": {}, - "environment_variables": [], - "configuration_options": [] - }, - "statistics": { - "total_commands": 67, - "commands_with_aliases": 0, - "commands_with_flags": 17, - "total_flags": 24, - "hidden_commands": 0, - "auth_required": 64, - "project_required": 44, - "plan_required": 45 - } -} \ No newline at end of file diff --git a/docs/reference/cli_inventory.yaml b/docs/reference/cli_inventory.yaml deleted file mode 100644 index 216bb3d22..000000000 --- a/docs/reference/cli_inventory.yaml +++ /dev/null @@ -1,1213 +0,0 @@ -root: - name: root - use: plandex [command] [flags] - aliases: [] - short_description: 'Plandex: iterative development with AI' - long_description: '' - flags: [] - subcommands: - - helpCmd - - connectClaudeCmd - - disconnectClaudeCmd - parent: null - run_function: func - file_path: /app/plandex/app/cli/cmd/root.go - requires_auth: false - requires_project: false - requires_plan: false - hidden: false -commands: - apply: - name: apply - use: apply - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/apply.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - archive: - name: archive - use: archive [name-or-index] - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/archive.go - requires_auth: true - requires_project: true - requires_plan: false - hidden: false - billing: - name: billing - use: billing - aliases: [] - short_description: Open the billing page in the browser - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: billing - file_path: /app/plandex/app/cli/cmd/billing.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - branches: - name: branches - use: branches - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/branches.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - browser: - name: browser - use: browser [urls...] - aliases: [] - short_description: Open browser windows with given URLs, capturing console logs - and exiting on JS errors - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/browser.go - requires_auth: false - requires_project: false - requires_plan: false - hidden: false - build: - name: build - use: build - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/build.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - cd: - name: cd - use: cd [name-or-index] - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/cd.go - requires_auth: true - requires_project: true - requires_plan: false - hidden: false - chat: - name: chat - use: chat [prompt] - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/chat.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - checkout: - name: checkout - use: checkout [name-or-index] - aliases: [] - short_description: '' - long_description: '' - flags: - - name: 'yes' - shorthand: y - flag_type: bool - default_value: false - description: Confirm creating a new branch - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/checkout.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - connect-claude: - name: connect-claude - use: connect-claude - aliases: [] - short_description: Connect your Claude Pro or Max subscription - long_description: '' - flags: [] - subcommands: [] - parent: root - run_function: connectClaude - file_path: /app/plandex/app/cli/cmd/claude_max.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - disconnect-claude: - name: disconnect-claude - use: disconnect-claude - aliases: [] - short_description: Disconnect your Claude Pro or Max subscription - long_description: '' - flags: [] - subcommands: [] - parent: root - run_function: disconnectClaude - file_path: /app/plandex/app/cli/cmd/claude_max.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - claude-status: - name: claude-status - use: claude-status - aliases: [] - short_description: Check the status of your Claude Pro or Max subscription - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: claudeStatus - file_path: /app/plandex/app/cli/cmd/claude_max.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - clear: - name: clear - use: clear - aliases: [] - short_description: Clear all context - long_description: Clear all context. - flags: [] - subcommands: [] - parent: null - run_function: clearAllContext - file_path: /app/plandex/app/cli/cmd/clear.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - config: - name: config - use: config - aliases: [] - short_description: Show plan config - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: config - file_path: /app/plandex/app/cli/cmd/config.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - default-config: - name: default-config - use: default - aliases: [] - short_description: Show default config for new plans - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: defaultConfig - file_path: /app/plandex/app/cli/cmd/config.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - connect: - name: connect - use: connect [stream-id-or-plan] [branch] - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/connect.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - context-show: - name: context-show - use: show [name-or-index] - aliases: [] - short_description: Show the body of a context by name or list index - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/context_show.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - continue: - name: continue - use: continue - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/continue.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - convo: - name: convo - use: convo [msg-range] - aliases: [] - short_description: Display complete conversation history - long_description: Display complete conversation history. Optionally specify a - message number or range of messages (e.g. '1' or '5' or '1-5' or '5-') - flags: - - name: plain - shorthand: p - flag_type: bool - default_value: false - description: Output conversation in plain text with no ANSI codes - required: false - global_flag: false - subcommands: [] - parent: null - run_function: convo - file_path: /app/plandex/app/cli/cmd/convo.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - current: - name: current - use: current - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/current.go - requires_auth: true - requires_project: false - requires_plan: true - hidden: false - debug: - name: debug - use: debug [tries] - aliases: [] - short_description: '' - long_description: '' - flags: - - name: commit - shorthand: c - flag_type: bool - default_value: false - description: Commit changes after successful execution - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/debug.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - delete-branch: - name: delete-branch - use: delete-branch - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/delete_branch.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - rm: - name: rm - use: delete-plan [name-or-index] - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/delete_plan.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - diffs: - name: diffs - use: diff - aliases: [] - short_description: '' - long_description: '' - flags: - - name: plain - shorthand: p - flag_type: bool - default_value: false - description: Output diffs in plain text with no ANSI codes - required: false - global_flag: false - - name: side - shorthand: s - flag_type: bool - default_value: true - description: Show diffs UI in side-by-side view - required: false - global_flag: false - - name: line - shorthand: l - flag_type: bool - default_value: false - description: Show diffs UI in line-by-line view - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/diffs.go - requires_auth: true - requires_project: false - requires_plan: true - hidden: false - invite: - name: invite - use: invite [email] [name] [org-role] - aliases: [] - short_description: Invite a new user to the org - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: invite - file_path: /app/plandex/app/cli/cmd/invite.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - context-load: - name: context-load - use: load [files-or-urls...] - aliases: [] - short_description: '' - long_description: '' - flags: - - name: recursive - shorthand: r - flag_type: bool - default_value: false - description: Search directories recursively - required: false - global_flag: false - - name: force - shorthand: f - flag_type: bool - default_value: false - description: Load files even when ignored by .gitignore or .plandexignore - required: false - global_flag: false - - name: note - shorthand: n - flag_type: string - default_value: '' - description: Add a note to the context - required: false - global_flag: false - - name: detail - shorthand: d - flag_type: string - default_value: high - description: Image detail level (high or low) - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/load.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - log: - name: log - use: log - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/log.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - context: - name: context - use: ls - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/ls.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - model-packs: - name: model-packs - use: model-packs - aliases: [] - short_description: List all model packs - long_description: '' - flags: - - name: custom - shorthand: c - flag_type: bool - default_value: false - description: Only show custom model packs - required: false - global_flag: false - - name: all - shorthand: a - flag_type: bool - default_value: false - description: Show all properties - required: false - global_flag: false - subcommands: [] - parent: null - run_function: listModelPacks - file_path: /app/plandex/app/cli/cmd/model_packs.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - create-model-pack: - name: create-model-pack - use: create - aliases: [] - short_description: Create a model pack - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: customModelsNotImplemented - file_path: /app/plandex/app/cli/cmd/model_packs.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - delete-model-pack: - name: delete-model-pack - use: delete - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/model_packs.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - update-model-pack: - name: update-model-pack - use: update - aliases: [] - short_description: Update a model pack by name - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: customModelsNotImplemented - file_path: /app/plandex/app/cli/cmd/model_packs.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - show-model-pack: - name: show-model-pack - use: show [name] - aliases: [] - short_description: Show a model pack by name - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: showModelPack - file_path: /app/plandex/app/cli/cmd/model_packs.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - providers: - name: providers - use: providers - aliases: [] - short_description: List built-in and custom model providers - long_description: '' - flags: - - name: custom - shorthand: c - flag_type: bool - default_value: false - description: List custom providers only - required: false - global_flag: false - subcommands: [] - parent: null - run_function: listProviders - file_path: /app/plandex/app/cli/cmd/model_providers.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - add-provider: - name: add-provider - use: add - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/model_providers.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - update-provider: - name: update-provider - use: update - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/model_providers.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - models: - name: models - use: models - aliases: [] - short_description: Show plan model settings - long_description: '' - flags: - - name: all - shorthand: a - flag_type: bool - default_value: false - description: Show all properties - required: false - global_flag: false - subcommands: [] - parent: null - run_function: models - file_path: /app/plandex/app/cli/cmd/models.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - default-models: - name: default-models - use: default - aliases: [] - short_description: Show default model settings for new plans - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: defaultModels - file_path: /app/plandex/app/cli/cmd/models.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - list-available-models: - name: list-available-models - use: available - aliases: [] - short_description: '' - long_description: '' - flags: - - name: custom - shorthand: c - flag_type: bool - default_value: false - description: List custom models only - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/models.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - manage-custom-models: - name: manage-custom-models - use: custom - aliases: [] - short_description: Manage custom models, providers, and model packs - long_description: '' - flags: - - name: file - shorthand: f - flag_type: string - default_value: '' - description: Path to custom models file - required: false - global_flag: false - subcommands: [] - parent: null - run_function: manageCustomModels - file_path: /app/plandex/app/cli/cmd/models.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - add-custom-model: - name: add-custom-model - use: add - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/models.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - update-custom-model: - name: update-custom-model - use: update - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/models.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - delete-custom-model: - name: delete-custom-model - use: rm - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/models.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - new: - name: new - use: new - aliases: [] - short_description: '' - long_description: '' - flags: - - name: name - shorthand: n - flag_type: string - default_value: '' - description: Name of the new plan - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/new.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - plans: - name: plans - use: plans - aliases: [] - short_description: '' - long_description: '' - flags: - - name: archived - shorthand: a - flag_type: bool - default_value: false - description: List archived plans - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/plans.go - requires_auth: true - requires_project: false - requires_plan: true - hidden: false - ps: - name: ps - use: ps - aliases: [] - short_description: List plans with active or recently finished streams - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: ps - file_path: /app/plandex/app/cli/cmd/ps.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - reject: - name: reject - use: reject [files...] - aliases: [] - short_description: '' - long_description: '' - flags: - - name: all - shorthand: a - flag_type: bool - default_value: false - description: Reject all pending changes - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/reject.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - rename: - name: rename - use: rename [new-name] - aliases: [] - short_description: Rename the current plan - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: rename - file_path: /app/plandex/app/cli/cmd/rename.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - repl: - name: repl - use: repl - aliases: [] - short_description: Start interactive Plandex REPL - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: runRepl - file_path: /app/plandex/app/cli/cmd/repl.go - requires_auth: true - requires_project: false - requires_plan: true - hidden: false - revoke: - name: revoke - use: revoke [email] - aliases: [] - short_description: Revoke an invite or remove a user from the org - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: revoke - file_path: /app/plandex/app/cli/cmd/revoke.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - rewind: - name: rewind - use: rewind [steps-or-sha] - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/rewind.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - context-rm: - name: context-rm - use: rm - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/rm.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - set-config: - name: set-config - use: set-config [setting] [value] - aliases: [] - short_description: Update current plan config - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: setConfig - file_path: /app/plandex/app/cli/cmd/set_config.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - default-set-config: - name: default-set-config - use: default [setting] [value] - aliases: [] - short_description: Update default plan config - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: defaultSetConfig - file_path: /app/plandex/app/cli/cmd/set_config.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - set-auto: - name: set-auto - use: set-auto [value] - aliases: [] - short_description: Update config auto-mode - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: setAuto - file_path: /app/plandex/app/cli/cmd/set_config.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - set-auto-default: - name: set-auto-default - use: default [value] - aliases: [] - short_description: Update default config auto-mode - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: setAutoDefault - file_path: /app/plandex/app/cli/cmd/set_config.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - models-set: - name: models-set - use: set-model [model-pack-name] - aliases: [] - short_description: '' - long_description: '' - flags: - - name: file - shorthand: f - flag_type: string - default_value: '' - description: Path to model settings JSON file - required: false - global_flag: false - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/set_model.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - default-model-set: - name: default-model-set - use: default [model-pack-name] - aliases: [] - short_description: Update org-wide default model settings - long_description: '' - flags: - - name: file - shorthand: f - flag_type: string - default_value: '' - description: Path to model settings JSON file - required: false - global_flag: false - subcommands: [] - parent: null - run_function: defaultModelsSet - file_path: /app/plandex/app/cli/cmd/set_model.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - sign-in: - name: sign-in - use: sign-in - aliases: [] - short_description: Sign in to a Plandex account - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: signIn - file_path: /app/plandex/app/cli/cmd/sign_in.go - requires_auth: false - requires_project: false - requires_plan: false - hidden: false - stop: - name: stop - use: stop [stream-id-or-plan] [branch] - aliases: [] - short_description: Connect to an active stream - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: stop - file_path: /app/plandex/app/cli/cmd/stop.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - status: - name: status - use: summary - aliases: [] - short_description: Show the latest summary of the current plan - long_description: '' - flags: - - name: plain - shorthand: p - flag_type: bool - default_value: false - description: Output summary in plain text with no ANSI codes - required: false - global_flag: false - subcommands: [] - parent: null - run_function: status - file_path: /app/plandex/app/cli/cmd/summary.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - tell: - name: tell - use: tell [prompt] - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/tell.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - unarchive: - name: unarchive - use: unarchive [name-or-index] - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/unarchive.go - requires_auth: true - requires_project: true - requires_plan: false - hidden: false - update: - name: update - use: update - aliases: [] - short_description: '' - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: null - file_path: /app/plandex/app/cli/cmd/update.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - usage: - name: usage - use: usage - aliases: [] - short_description: Display credits balance and usage report - long_description: '' - flags: - - name: page-size - shorthand: s - flag_type: int - default_value: 100 - description: Number of transactions to display per page - required: false - global_flag: false - - name: page - shorthand: p - flag_type: int - default_value: 1 - description: Page number to display - required: false - global_flag: false - subcommands: [] - parent: null - run_function: usage - file_path: /app/plandex/app/cli/cmd/usage.go - requires_auth: true - requires_project: true - requires_plan: true - hidden: false - users: - name: users - use: users - aliases: [] - short_description: List all users and pending invites and the current org - long_description: '' - flags: [] - subcommands: [] - parent: null - run_function: listUsersAndInvites - file_path: /app/plandex/app/cli/cmd/users.go - requires_auth: true - requires_project: false - requires_plan: false - hidden: false - version: - name: version - use: version - aliases: [] - short_description: Print the version number of Plandex - long_description: All software has versions. This is Plandex's - flags: [] - subcommands: [] - parent: null - run_function: func - file_path: /app/plandex/app/cli/cmd/version.go - requires_auth: false - requires_project: false - requires_plan: false - hidden: false -hierarchy: - root: - subcommands: - - connect-claude - - disconnect-claude -metadata: - repl_commands: [] - shortcuts: {} - environment_variables: [] - configuration_options: [] -statistics: - total_commands: 67 - commands_with_aliases: 0 - commands_with_flags: 17 - total_flags: 24 - hidden_commands: 0 - auth_required: 64 - project_required: 44 - plan_required: 45 diff --git a/docs/reference/cloud/cloud_features.json b/docs/reference/cloud/cloud_features.json deleted file mode 100644 index 21b5cbfd8..000000000 --- a/docs/reference/cloud/cloud_features.json +++ /dev/null @@ -1,416 +0,0 @@ -{ - "cloud_features": { - "billing_ui": { - "category": "billing", - "description": "Web-based billing and subscription UI", - "action": "remove", - "go_references": [ - "app/cli/cmd/billing.go", - "app/server/handlers/billing_handlers.go", - "app/shared/billing.go" - ], - "ui_elements": [ - "Billing dashboard links", - "Subscription status display", - "Payment method prompts" - ], - "replacement": "Documentation on self-hosting costs", - "priority": "high", - "notes": "Replace with self-host cost estimation guide" - }, - "usage_limits": { - "category": "billing", - "description": "Usage-based limits and quotas", - "action": "replace", - "go_references": [ - "app/server/middleware/usage_limits.go", - "app/shared/usage.go" - ], - "functionality": [ - "API call limits", - "Storage quotas", - "Team size limits" - ], - "replacement": "Configurable local limits", - "priority": "medium", - "notes": "Make limits configurable via settings" - }, - "usage_telemetry": { - "category": "telemetry", - "description": "Usage tracking and analytics", - "action": "replace", - "go_references": [ - "app/cli/lib/telemetry.go", - "app/server/telemetry/telemetry.go", - "app/shared/telemetry.go" - ], - "data_collected": [ - "Command usage statistics", - "Model usage metrics", - "Error tracking", - "Performance metrics" - ], - "replacement": "Opt-in local telemetry with OpenTelemetry", - "priority": "medium", - "notes": "Default to disabled, provide local dashboard option" - }, - "error_reporting": { - "category": "telemetry", - "description": "Centralized error reporting service", - "action": "replace", - "go_references": [ - "app/cli/lib/error_reporting.go", - "app/server/errors/reporting.go" - ], - "services": [ - "Sentry integration", - "Error aggregation", - "Alert notifications" - ], - "replacement": "Local error logging with optional export", - "priority": "low", - "notes": "Use structured logging with export options" - }, - "managed_auth": { - "category": "managed_auth", - "description": "Cloud-based authentication service", - "action": "replace", - "go_references": [ - "app/server/auth/cloud_auth.go", - "app/cli/lib/auth_cloud.go", - "app/shared/auth.go" - ], - "functionality": [ - "OAuth providers", - "SSO integration", - "Password reset emails", - "Email verification" - ], - "replacement": "Local auth with optional LDAP/SAML", - "priority": "high", - "notes": "Implement local user management with pluggable auth" - }, - "api_keys_cloud": { - "category": "managed_auth", - "description": "Cloud-managed API keys", - "action": "replace", - "go_references": [ - "app/server/api/keys.go", - "app/cli/cmd/api_keys.go" - ], - "functionality": [ - "Key generation", - "Key rotation", - "Usage tracking per key" - ], - "replacement": "Local API key management", - "priority": "medium", - "notes": "Store encrypted keys locally" - }, - "cloud_backups": { - "category": "cloud_storage", - "description": "Automated cloud backups", - "action": "remove", - "go_references": [ - "app/server/backup/cloud_backup.go", - "app/cli/cmd/backup.go" - ], - "functionality": [ - "Automated S3 backups", - "Point-in-time recovery", - "Cross-region replication" - ], - "replacement": "Local backup documentation", - "priority": "low", - "notes": "Provide backup scripts and best practices" - }, - "cdn_assets": { - "category": "cloud_storage", - "description": "CDN-hosted static assets", - "action": "replace", - "go_references": [ - "app/server/static/cdn.go", - "app/shared/assets.go" - ], - "assets": [ - "Documentation images", - "UI components", - "Model metadata" - ], - "replacement": "Bundle assets in distribution", - "priority": "medium", - "notes": "Include all assets in package" - }, - "email_service": { - "category": "notifications", - "description": "Cloud email service integration", - "action": "replace", - "go_references": [ - "app/server/email/sendgrid.go", - "app/server/email/ses.go", - "app/shared/notifications.go" - ], - "functionality": [ - "Invite emails", - "Password reset", - "Notifications", - "Reports" - ], - "replacement": "SMTP configuration with local mail server", - "priority": "high", - "notes": "Support standard SMTP with templates" - }, - "push_notifications": { - "category": "notifications", - "description": "Mobile/desktop push notifications", - "action": "remove", - "go_references": [ - "app/server/push/push.go", - "app/cli/lib/notifications.go" - ], - "services": [ - "Firebase messaging", - "APNS", - "Web push" - ], - "replacement": "In-app notifications only", - "priority": "low", - "notes": "Focus on CLI/TUI notifications" - }, - "org_management": { - "category": "team_management", - "description": "Cloud-based organization management", - "action": "replace", - "go_references": [ - "app/server/org/org_management.go", - "app/cli/cmd/org.go", - "app/shared/org.go" - ], - "functionality": [ - "Org creation", - "Member management", - "Role assignment", - "Billing per org" - ], - "replacement": "Local team management with roles", - "priority": "medium", - "notes": "Simplified local team structure" - }, - "team_sync": { - "category": "team_management", - "description": "Real-time team state synchronization", - "action": "replace", - "go_references": [ - "app/server/sync/team_sync.go", - "app/shared/sync.go" - ], - "functionality": [ - "Real-time updates", - "Presence tracking", - "Shared contexts" - ], - "replacement": "Database-based sync for multi-user mode", - "priority": "low", - "notes": "Use DB polling or websockets locally" - }, - "api_proxy": { - "category": "api_proxying", - "description": "Cloud API key proxying service", - "action": "remove", - "go_references": [ - "app/server/proxy/api_proxy.go", - "app/cli/lib/proxy.go" - ], - "functionality": [ - "Hide user API keys", - "Rate limit per user", - "Usage tracking", - "Cost allocation" - ], - "replacement": "Direct API usage with user keys", - "priority": "high", - "notes": "Users manage their own provider API keys" - }, - "legacy_models": { - "category": "deprecated", - "description": "Support for deprecated model versions", - "action": "remove", - "go_references": [ - "app/shared/deprecated_models.go", - "app/cli/lib/legacy_models.go" - ], - "models": [ - "GPT-3 variants", - "Claude v1", - "Old Codex models" - ], - "replacement": "Current models only", - "priority": "low", - "notes": "Remove support for EOL models" - }, - "old_api_versions": { - "category": "deprecated", - "description": "Backward compatibility with old API versions", - "action": "remove", - "go_references": [ - "app/server/handlers/v1/", - "app/server/handlers/v2/" - ], - "versions": [ - "API v1", - "API v2", - "Legacy endpoints" - ], - "replacement": "Single current API version", - "priority": "medium", - "notes": "CleverAgents starts fresh with v1 only" - } - }, - "replacements": { - "remove": [ - { - "feature": "billing_ui", - "description": "Web-based billing and subscription UI", - "replacement": "Documentation on self-hosting costs", - "priority": "high", - "notes": "Replace with self-host cost estimation guide" - }, - { - "feature": "api_proxy", - "description": "Cloud API key proxying service", - "replacement": "Direct API usage with user keys", - "priority": "high", - "notes": "Users manage their own provider API keys" - }, - { - "feature": "old_api_versions", - "description": "Backward compatibility with old API versions", - "replacement": "Single current API version", - "priority": "medium", - "notes": "CleverAgents starts fresh with v1 only" - }, - { - "feature": "cloud_backups", - "description": "Automated cloud backups", - "replacement": "Local backup documentation", - "priority": "low", - "notes": "Provide backup scripts and best practices" - }, - { - "feature": "push_notifications", - "description": "Mobile/desktop push notifications", - "replacement": "In-app notifications only", - "priority": "low", - "notes": "Focus on CLI/TUI notifications" - }, - { - "feature": "legacy_models", - "description": "Support for deprecated model versions", - "replacement": "Current models only", - "priority": "low", - "notes": "Remove support for EOL models" - } - ], - "replace": [ - { - "feature": "managed_auth", - "description": "Cloud-based authentication service", - "replacement": "Local auth with optional LDAP/SAML", - "priority": "high", - "notes": "Implement local user management with pluggable auth" - }, - { - "feature": "email_service", - "description": "Cloud email service integration", - "replacement": "SMTP configuration with local mail server", - "priority": "high", - "notes": "Support standard SMTP with templates" - }, - { - "feature": "usage_limits", - "description": "Usage-based limits and quotas", - "replacement": "Configurable local limits", - "priority": "medium", - "notes": "Make limits configurable via settings" - }, - { - "feature": "usage_telemetry", - "description": "Usage tracking and analytics", - "replacement": "Opt-in local telemetry with OpenTelemetry", - "priority": "medium", - "notes": "Default to disabled, provide local dashboard option" - }, - { - "feature": "api_keys_cloud", - "description": "Cloud-managed API keys", - "replacement": "Local API key management", - "priority": "medium", - "notes": "Store encrypted keys locally" - }, - { - "feature": "cdn_assets", - "description": "CDN-hosted static assets", - "replacement": "Bundle assets in distribution", - "priority": "medium", - "notes": "Include all assets in package" - }, - { - "feature": "org_management", - "description": "Cloud-based organization management", - "replacement": "Local team management with roles", - "priority": "medium", - "notes": "Simplified local team structure" - }, - { - "feature": "error_reporting", - "description": "Centralized error reporting service", - "replacement": "Local error logging with optional export", - "priority": "low", - "notes": "Use structured logging with export options" - }, - { - "feature": "team_sync", - "description": "Real-time team state synchronization", - "replacement": "Database-based sync for multi-user mode", - "priority": "low", - "notes": "Use DB polling or websockets locally" - } - ], - "defer": [] - }, - "statistics": { - "total_features": 15, - "by_category": { - "billing": 2, - "telemetry": 2, - "managed_auth": 2, - "cloud_storage": 2, - "notifications": 2, - "team_management": 2, - "api_proxying": 1, - "deprecated": 2 - }, - "by_action": { - "remove": 6, - "replace": 9, - "defer": 0 - }, - "by_priority": { - "high": 4, - "medium": 6, - "low": 5 - }, - "go_files_affected": 35, - "functionality_count": 28 - }, - "categories": { - "billing": "Payment processing and subscription management", - "telemetry": "Usage tracking and analytics", - "managed_auth": "Centralized authentication service", - "cloud_storage": "Cloud-based data storage", - "notifications": "Cloud notification services", - "rate_limiting": "Cloud-based rate limiting", - "team_management": "Centralized team/org management", - "api_proxying": "API key management and proxying" - } -} \ No newline at end of file diff --git a/docs/reference/cloud/cloud_features.md b/docs/reference/cloud/cloud_features.md deleted file mode 100644 index c934600e6..000000000 --- a/docs/reference/cloud/cloud_features.md +++ /dev/null @@ -1,243 +0,0 @@ -# Cloud-Only Features Analysis - -Features that need removal or replacement for self-hosted CleverAgents. - -## Summary - -- Total cloud features identified: 15 -- Features to remove: 6 -- Features to replace: 9 -- Go files affected: 35 - -## Replacement Strategies - -### Features to Remove - -These features should be completely removed: - -- **billing_ui** (high priority) - - Web-based billing and subscription UI - - Notes: Replace with self-host cost estimation guide - -- **api_proxy** (high priority) - - Cloud API key proxying service - - Notes: Users manage their own provider API keys - -- **old_api_versions** (medium priority) - - Backward compatibility with old API versions - - Notes: CleverAgents starts fresh with v1 only - -- **cloud_backups** (low priority) - - Automated cloud backups - - Notes: Provide backup scripts and best practices - -- **push_notifications** (low priority) - - Mobile/desktop push notifications - - Notes: Focus on CLI/TUI notifications - -- **legacy_models** (low priority) - - Support for deprecated model versions - - Notes: Remove support for EOL models - -### Features to Replace - -These features need local alternatives: - -- **managed_auth** (high priority) - - Cloud-based authentication service - - Replacement: Local auth with optional LDAP/SAML - - Notes: Implement local user management with pluggable auth - -- **email_service** (high priority) - - Cloud email service integration - - Replacement: SMTP configuration with local mail server - - Notes: Support standard SMTP with templates - -- **usage_limits** (medium priority) - - Usage-based limits and quotas - - Replacement: Configurable local limits - - Notes: Make limits configurable via settings - -- **usage_telemetry** (medium priority) - - Usage tracking and analytics - - Replacement: Opt-in local telemetry with OpenTelemetry - - Notes: Default to disabled, provide local dashboard option - -- **api_keys_cloud** (medium priority) - - Cloud-managed API keys - - Replacement: Local API key management - - Notes: Store encrypted keys locally - -- **cdn_assets** (medium priority) - - CDN-hosted static assets - - Replacement: Bundle assets in distribution - - Notes: Include all assets in package - -- **org_management** (medium priority) - - Cloud-based organization management - - Replacement: Local team management with roles - - Notes: Simplified local team structure - -- **error_reporting** (low priority) - - Centralized error reporting service - - Replacement: Local error logging with optional export - - Notes: Use structured logging with export options - -- **team_sync** (low priority) - - Real-time team state synchronization - - Replacement: Database-based sync for multi-user mode - - Notes: Use DB polling or websockets locally - -## Detailed Analysis by Category - -### Billing -Payment processing and subscription management - -#### Billing Ui -- **Action**: remove -- **Priority**: high -- **Description**: Web-based billing and subscription UI -- **Replacement**: Documentation on self-hosting costs -- **Notes**: Replace with self-host cost estimation guide - -#### Usage Limits -- **Action**: replace -- **Priority**: medium -- **Description**: Usage-based limits and quotas -- **Functionality**: - - API call limits - - Storage quotas - - Team size limits -- **Replacement**: Configurable local limits -- **Notes**: Make limits configurable via settings - -### Telemetry -Usage tracking and analytics - -#### Usage Telemetry -- **Action**: replace -- **Priority**: medium -- **Description**: Usage tracking and analytics -- **Replacement**: Opt-in local telemetry with OpenTelemetry -- **Notes**: Default to disabled, provide local dashboard option - -#### Error Reporting -- **Action**: replace -- **Priority**: low -- **Description**: Centralized error reporting service -- **Replacement**: Local error logging with optional export -- **Notes**: Use structured logging with export options - -### Managed Auth -Centralized authentication service - -#### Managed Auth -- **Action**: replace -- **Priority**: high -- **Description**: Cloud-based authentication service -- **Functionality**: - - OAuth providers - - SSO integration - - Password reset emails - - Email verification -- **Replacement**: Local auth with optional LDAP/SAML -- **Notes**: Implement local user management with pluggable auth - -#### Api Keys Cloud -- **Action**: replace -- **Priority**: medium -- **Description**: Cloud-managed API keys -- **Functionality**: - - Key generation - - Key rotation - - Usage tracking per key -- **Replacement**: Local API key management -- **Notes**: Store encrypted keys locally - -### Cloud Storage -Cloud-based data storage - -#### Cloud Backups -- **Action**: remove -- **Priority**: low -- **Description**: Automated cloud backups -- **Functionality**: - - Automated S3 backups - - Point-in-time recovery - - Cross-region replication -- **Replacement**: Local backup documentation -- **Notes**: Provide backup scripts and best practices - -#### Cdn Assets -- **Action**: replace -- **Priority**: medium -- **Description**: CDN-hosted static assets -- **Replacement**: Bundle assets in distribution -- **Notes**: Include all assets in package - -### Notifications -Cloud notification services - -#### Email Service -- **Action**: replace -- **Priority**: high -- **Description**: Cloud email service integration -- **Functionality**: - - Invite emails - - Password reset - - Notifications - - Reports -- **Replacement**: SMTP configuration with local mail server -- **Notes**: Support standard SMTP with templates - -#### Push Notifications -- **Action**: remove -- **Priority**: low -- **Description**: Mobile/desktop push notifications -- **Replacement**: In-app notifications only -- **Notes**: Focus on CLI/TUI notifications - -### Rate Limiting -Cloud-based rate limiting - -### Team Management -Centralized team/org management - -#### Org Management -- **Action**: replace -- **Priority**: medium -- **Description**: Cloud-based organization management -- **Functionality**: - - Org creation - - Member management - - Role assignment - - Billing per org -- **Replacement**: Local team management with roles -- **Notes**: Simplified local team structure - -#### Team Sync -- **Action**: replace -- **Priority**: low -- **Description**: Real-time team state synchronization -- **Functionality**: - - Real-time updates - - Presence tracking - - Shared contexts -- **Replacement**: Database-based sync for multi-user mode -- **Notes**: Use DB polling or websockets locally - -### Api Proxying -API key management and proxying - -#### Api Proxy -- **Action**: remove -- **Priority**: high -- **Description**: Cloud API key proxying service -- **Functionality**: - - Hide user API keys - - Rate limit per user - - Usage tracking - - Cost allocation -- **Replacement**: Direct API usage with user keys -- **Notes**: Users manage their own provider API keys - diff --git a/docs/reference/cloud/cloud_features.yaml b/docs/reference/cloud/cloud_features.yaml deleted file mode 100644 index 88e3eaed5..000000000 --- a/docs/reference/cloud/cloud_features.yaml +++ /dev/null @@ -1,330 +0,0 @@ -cloud_features: - billing_ui: - category: billing - description: Web-based billing and subscription UI - action: remove - go_references: - - app/cli/cmd/billing.go - - app/server/handlers/billing_handlers.go - - app/shared/billing.go - ui_elements: - - Billing dashboard links - - Subscription status display - - Payment method prompts - replacement: Documentation on self-hosting costs - priority: high - notes: Replace with self-host cost estimation guide - usage_limits: - category: billing - description: Usage-based limits and quotas - action: replace - go_references: - - app/server/middleware/usage_limits.go - - app/shared/usage.go - functionality: - - API call limits - - Storage quotas - - Team size limits - replacement: Configurable local limits - priority: medium - notes: Make limits configurable via settings - usage_telemetry: - category: telemetry - description: Usage tracking and analytics - action: replace - go_references: - - app/cli/lib/telemetry.go - - app/server/telemetry/telemetry.go - - app/shared/telemetry.go - data_collected: - - Command usage statistics - - Model usage metrics - - Error tracking - - Performance metrics - replacement: Opt-in local telemetry with OpenTelemetry - priority: medium - notes: Default to disabled, provide local dashboard option - error_reporting: - category: telemetry - description: Centralized error reporting service - action: replace - go_references: - - app/cli/lib/error_reporting.go - - app/server/errors/reporting.go - services: - - Sentry integration - - Error aggregation - - Alert notifications - replacement: Local error logging with optional export - priority: low - notes: Use structured logging with export options - managed_auth: - category: managed_auth - description: Cloud-based authentication service - action: replace - go_references: - - app/server/auth/cloud_auth.go - - app/cli/lib/auth_cloud.go - - app/shared/auth.go - functionality: - - OAuth providers - - SSO integration - - Password reset emails - - Email verification - replacement: Local auth with optional LDAP/SAML - priority: high - notes: Implement local user management with pluggable auth - api_keys_cloud: - category: managed_auth - description: Cloud-managed API keys - action: replace - go_references: - - app/server/api/keys.go - - app/cli/cmd/api_keys.go - functionality: - - Key generation - - Key rotation - - Usage tracking per key - replacement: Local API key management - priority: medium - notes: Store encrypted keys locally - cloud_backups: - category: cloud_storage - description: Automated cloud backups - action: remove - go_references: - - app/server/backup/cloud_backup.go - - app/cli/cmd/backup.go - functionality: - - Automated S3 backups - - Point-in-time recovery - - Cross-region replication - replacement: Local backup documentation - priority: low - notes: Provide backup scripts and best practices - cdn_assets: - category: cloud_storage - description: CDN-hosted static assets - action: replace - go_references: - - app/server/static/cdn.go - - app/shared/assets.go - assets: - - Documentation images - - UI components - - Model metadata - replacement: Bundle assets in distribution - priority: medium - notes: Include all assets in package - email_service: - category: notifications - description: Cloud email service integration - action: replace - go_references: - - app/server/email/sendgrid.go - - app/server/email/ses.go - - app/shared/notifications.go - functionality: - - Invite emails - - Password reset - - Notifications - - Reports - replacement: SMTP configuration with local mail server - priority: high - notes: Support standard SMTP with templates - push_notifications: - category: notifications - description: Mobile/desktop push notifications - action: remove - go_references: - - app/server/push/push.go - - app/cli/lib/notifications.go - services: - - Firebase messaging - - APNS - - Web push - replacement: In-app notifications only - priority: low - notes: Focus on CLI/TUI notifications - org_management: - category: team_management - description: Cloud-based organization management - action: replace - go_references: - - app/server/org/org_management.go - - app/cli/cmd/org.go - - app/shared/org.go - functionality: - - Org creation - - Member management - - Role assignment - - Billing per org - replacement: Local team management with roles - priority: medium - notes: Simplified local team structure - team_sync: - category: team_management - description: Real-time team state synchronization - action: replace - go_references: - - app/server/sync/team_sync.go - - app/shared/sync.go - functionality: - - Real-time updates - - Presence tracking - - Shared contexts - replacement: Database-based sync for multi-user mode - priority: low - notes: Use DB polling or websockets locally - api_proxy: - category: api_proxying - description: Cloud API key proxying service - action: remove - go_references: - - app/server/proxy/api_proxy.go - - app/cli/lib/proxy.go - functionality: - - Hide user API keys - - Rate limit per user - - Usage tracking - - Cost allocation - replacement: Direct API usage with user keys - priority: high - notes: Users manage their own provider API keys - legacy_models: - category: deprecated - description: Support for deprecated model versions - action: remove - go_references: - - app/shared/deprecated_models.go - - app/cli/lib/legacy_models.go - models: - - GPT-3 variants - - Claude v1 - - Old Codex models - replacement: Current models only - priority: low - notes: Remove support for EOL models - old_api_versions: - category: deprecated - description: Backward compatibility with old API versions - action: remove - go_references: - - app/server/handlers/v1/ - - app/server/handlers/v2/ - versions: - - API v1 - - API v2 - - Legacy endpoints - replacement: Single current API version - priority: medium - notes: CleverAgents starts fresh with v1 only -replacements: - remove: - - feature: billing_ui - description: Web-based billing and subscription UI - replacement: Documentation on self-hosting costs - priority: high - notes: Replace with self-host cost estimation guide - - feature: api_proxy - description: Cloud API key proxying service - replacement: Direct API usage with user keys - priority: high - notes: Users manage their own provider API keys - - feature: old_api_versions - description: Backward compatibility with old API versions - replacement: Single current API version - priority: medium - notes: CleverAgents starts fresh with v1 only - - feature: cloud_backups - description: Automated cloud backups - replacement: Local backup documentation - priority: low - notes: Provide backup scripts and best practices - - feature: push_notifications - description: Mobile/desktop push notifications - replacement: In-app notifications only - priority: low - notes: Focus on CLI/TUI notifications - - feature: legacy_models - description: Support for deprecated model versions - replacement: Current models only - priority: low - notes: Remove support for EOL models - replace: - - feature: managed_auth - description: Cloud-based authentication service - replacement: Local auth with optional LDAP/SAML - priority: high - notes: Implement local user management with pluggable auth - - feature: email_service - description: Cloud email service integration - replacement: SMTP configuration with local mail server - priority: high - notes: Support standard SMTP with templates - - feature: usage_limits - description: Usage-based limits and quotas - replacement: Configurable local limits - priority: medium - notes: Make limits configurable via settings - - feature: usage_telemetry - description: Usage tracking and analytics - replacement: Opt-in local telemetry with OpenTelemetry - priority: medium - notes: Default to disabled, provide local dashboard option - - feature: api_keys_cloud - description: Cloud-managed API keys - replacement: Local API key management - priority: medium - notes: Store encrypted keys locally - - feature: cdn_assets - description: CDN-hosted static assets - replacement: Bundle assets in distribution - priority: medium - notes: Include all assets in package - - feature: org_management - description: Cloud-based organization management - replacement: Local team management with roles - priority: medium - notes: Simplified local team structure - - feature: error_reporting - description: Centralized error reporting service - replacement: Local error logging with optional export - priority: low - notes: Use structured logging with export options - - feature: team_sync - description: Real-time team state synchronization - replacement: Database-based sync for multi-user mode - priority: low - notes: Use DB polling or websockets locally - defer: [] -statistics: - total_features: 15 - by_category: - billing: 2 - telemetry: 2 - managed_auth: 2 - cloud_storage: 2 - notifications: 2 - team_management: 2 - api_proxying: 1 - deprecated: 2 - by_action: - remove: 6 - replace: 9 - defer: 0 - by_priority: - high: 4 - medium: 6 - low: 5 - go_files_affected: 35 - functionality_count: 28 -categories: - billing: Payment processing and subscription management - telemetry: Usage tracking and analytics - managed_auth: Centralized authentication service - cloud_storage: Cloud-based data storage - notifications: Cloud notification services - rate_limiting: Cloud-based rate limiting - team_management: Centralized team/org management - api_proxying: API key management and proxying diff --git a/docs/reference/contracts/data_contracts.json b/docs/reference/contracts/data_contracts.json deleted file mode 100644 index 6d3f29101..000000000 --- a/docs/reference/contracts/data_contracts.json +++ /dev/null @@ -1,7568 +0,0 @@ -{ - "ai_models_credentials": { - "package_name": "shared", - "imports": [], - "structs": [ - { - "name": "ModelProviderOption", - "fields": [ - { - "name": "Publishers", - "type_name": "map[ModelPublisher]bool", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "Config", - "type_name": "ModelProviderConfigSchema", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "Priority", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_credentials.go", - "line_number": 3, - "is_exported": true - } - ], - "enums": [], - "type_aliases": [ - { - "name": "ModelProviderOptions", - "underlying_type": "map[string]ModelProviderOption", - "file_path": "/app/robot/../plandex/app/shared/ai_models_credentials.go", - "line_number": 9 - } - ] - }, - "ai_models_custom": { - "package_name": "shared", - "imports": [ - "crypto/sha256", - "encoding/hex", - "encoding/json", - "fmt", - "strings", - "time", - "github.com/google/go-cmp/cmp", - "github.com/google/go-cmp/cmp/cmpopts" - ], - "structs": [ - { - "name": "CustomModel", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ModelId", - "type_name": "ModelId", - "json_tag": "modelId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Publisher", - "type_name": "ModelPublisher", - "json_tag": "publisher", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Providers", - "type_name": "BaseModelUsesProvider", - "json_tag": "providers", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_custom.go", - "line_number": 25, - "is_exported": true - }, - { - "name": "CustomProvider", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "BaseUrl", - "type_name": "string", - "json_tag": "baseUrl", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "for AWS Bedrock models" - }, - { - "name": "HasAWSAuth", - "type_name": "bool", - "json_tag": "hasAWSAuth", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "for local models that don't require auth (ollama, etc.)" - }, - { - "name": "SkipAuth", - "type_name": "bool", - "json_tag": "skipAuth", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ApiKeyEnvVar", - "type_name": "string", - "json_tag": "apiKeyEnvVar", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ExtraAuthVars", - "type_name": "ModelProviderExtraAuthVars", - "json_tag": "extraAuthVars", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_custom.go", - "line_number": 39, - "is_exported": true - }, - { - "name": "ModelsInput", - "fields": [ - { - "name": "CustomModels", - "type_name": "*CustomModel", - "json_tag": "models", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CustomProviders", - "type_name": "*CustomProvider", - "json_tag": "providers", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CustomModelPacks", - "type_name": "*ModelPackSchema", - "json_tag": "modelPacks", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_custom.go", - "line_number": 57, - "is_exported": true - }, - { - "name": "ClientModelPackSchema", - "fields": [ - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_custom.go", - "line_number": 191, - "is_exported": true - }, - { - "name": "ClientModelsInput", - "fields": [ - { - "name": "SchemaUrl", - "type_name": "SchemaUrl", - "json_tag": "$schema", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CustomModels", - "type_name": "*CustomModel", - "json_tag": "models", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CustomProviders", - "type_name": "*CustomProvider", - "json_tag": "providers", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CustomModelPacks", - "type_name": "*ClientModelPackSchema", - "json_tag": "modelPacks", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_custom.go", - "line_number": 214, - "is_exported": true - } - ], - "enums": [ - { - "name": "SchemaUrl", - "type_name": "string", - "values": [ - "SchemaUrlInputConfig", - "SchemaUrlPlanConfig", - "SchemaUrlInlineModelPack" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_custom.go", - "line_number": 17 - } - ], - "type_aliases": [ - { - "name": "SchemaUrl", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_custom.go", - "line_number": 15 - } - ] - }, - "ai_models_data_models": { - "package_name": "shared", - "imports": [ - "crypto/sha256", - "database/sql/driver", - "encoding/hex", - "encoding/json", - "fmt", - "reflect", - "strings", - "time" - ], - "structs": [ - { - "name": "ModelCompatibility", - "fields": [ - { - "name": "HasImageSupport", - "type_name": "bool", - "json_tag": "hasImageSupport", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 14, - "is_exported": true - }, - { - "name": "BaseModelShared", - "fields": [ - { - "name": "DefaultMaxConvoTokens", - "type_name": "int", - "json_tag": "defaultMaxConvoTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MaxTokens", - "type_name": "int", - "json_tag": "maxTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MaxOutputTokens", - "type_name": "int", - "json_tag": "maxOutputTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ReservedOutputTokens", - "type_name": "int", - "json_tag": "reservedOutputTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PreferredOutputFormat", - "type_name": "ModelOutputFormat", - "json_tag": "preferredOutputFormat", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SystemPromptDisabled", - "type_name": "bool", - "json_tag": "systemPromptDisabled", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "RoleParamsDisabled", - "type_name": "bool", - "json_tag": "roleParamsDisabled", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "StopDisabled", - "type_name": "bool", - "json_tag": "stopDisabled", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PredictedOutputEnabled", - "type_name": "bool", - "json_tag": "predictedOutputEnabled", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ReasoningEffortEnabled", - "type_name": "bool", - "json_tag": "reasoningEffortEnabled", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ReasoningEffort", - "type_name": "ReasoningEffort", - "json_tag": "reasoningEffort", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IncludeReasoning", - "type_name": "bool", - "json_tag": "includeReasoning", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "HideReasoning", - "type_name": "bool", - "json_tag": "hideReasoning", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ReasoningBudget", - "type_name": "int", - "json_tag": "reasoningBudget", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SupportsCacheControl", - "type_name": "bool", - "json_tag": "supportsCacheControl", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SingleMessageNoSystemPrompt", - "type_name": "bool", - "json_tag": "singleMessageNoSystemPrompt", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TokenEstimatePaddingPct", - "type_name": "float64", - "json_tag": "tokenEstimatePaddingPct", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 31, - "is_exported": true - }, - { - "name": "BaseModelProviderConfig", - "fields": [ - { - "name": "ModelName", - "type_name": "ModelName", - "json_tag": "modelName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 52, - "is_exported": true - }, - { - "name": "BaseModelConfig", - "fields": [ - { - "name": "ModelTag", - "type_name": "ModelTag", - "json_tag": "modelTag", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ModelId", - "type_name": "ModelId", - "json_tag": "modelId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Publisher", - "type_name": "ModelPublisher", - "json_tag": "publisher", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "BaseModelShared", - "type_name": "BaseModelProviderConfig", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 57, - "is_exported": true - }, - { - "name": "BaseModelUsesProvider", - "fields": [ - { - "name": "Provider", - "type_name": "ModelProvider", - "json_tag": "provider", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CustomProvider", - "type_name": "string", - "json_tag": "customProvider", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "ModelName", - "type_name": "ModelName", - "json_tag": "modelName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 65, - "is_exported": true - }, - { - "name": "BaseModelConfigSchema", - "fields": [ - { - "name": "ModelTag", - "type_name": "ModelTag", - "json_tag": "modelTag", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ModelId", - "type_name": "ModelId", - "json_tag": "modelId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Publisher", - "type_name": "ModelPublisher", - "json_tag": "publisher", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "RequiresVariantOverrides", - "type_name": "string", - "json_tag": "requiresVariantOverrides", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "Variants", - "type_name": "BaseModelConfigVariant", - "json_tag": "variants", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "Providers", - "type_name": "BaseModelUsesProvider", - "json_tag": "providers", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 78, - "is_exported": true - }, - { - "name": "BaseModelConfigVariant", - "fields": [ - { - "name": "IsBaseVariant", - "type_name": "bool", - "json_tag": "isBaseVariant", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "VariantTag", - "type_name": "VariantTag", - "json_tag": "variantTag", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Overrides", - "type_name": "BaseModelShared", - "json_tag": "overrides", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Variants", - "type_name": "BaseModelConfigVariant", - "json_tag": "variants", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "RequiresVariantOverrides", - "type_name": "string", - "json_tag": "requiresVariantOverrides", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "IsDefaultVariant", - "type_name": "bool", - "json_tag": "isDefaultVariant", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 92, - "is_exported": true - }, - { - "name": "AvailableModel", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DefaultMaxConvoTokens", - "type_name": "int", - "json_tag": "defaultMaxConvoTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 256, - "is_exported": true - }, - { - "name": "PlannerModelConfig", - "fields": [ - { - "name": "MaxConvoTokens", - "type_name": "int", - "json_tag": "maxConvoTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 274, - "is_exported": true - }, - { - "name": "ModelRoleConfig", - "fields": [ - { - "name": "Role", - "type_name": "ModelRole", - "json_tag": "role", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ModelId", - "type_name": "ModelId", - "json_tag": "modelId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "new in 2.2.0 refactor \u2014 uses provider lookup instead of BaseModelConfig and MissingKeyFallback" - }, - { - "name": "BaseModelConfig", - "type_name": "BaseModelConfig", - "json_tag": "baseModelConfig", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "Temperature", - "type_name": "float32", - "json_tag": "temperature", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TopP", - "type_name": "float32", - "json_tag": "topP", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ReservedOutputTokens", - "type_name": "int", - "json_tag": "reservedOutputTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "LargeContextFallback", - "type_name": "ModelRoleConfig", - "json_tag": "largeContextFallback", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "LargeOutputFallback", - "type_name": "ModelRoleConfig", - "json_tag": "largeOutputFallback", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "ErrorFallback", - "type_name": "ModelRoleConfig", - "json_tag": "errorFallback", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false, - "comment": "MissingKeyFallback *ModelRoleConfig // removed in 2.2.0 refactor \u2014" - }, - { - "name": "StrongModel", - "type_name": "ModelRoleConfig", - "json_tag": "strongModel", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "LocalProvider", - "type_name": "ModelProvider", - "json_tag": "localProvider", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 286, - "is_exported": true - }, - { - "name": "ModelRoleModelConfig", - "fields": [ - { - "name": "Provider", - "type_name": "ModelProvider", - "json_tag": "provider", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CustomProvider", - "type_name": "string", - "json_tag": "customProvider", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "ModelTag", - "type_name": "ModelTag", - "json_tag": "modelTag", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 305, - "is_exported": true - }, - { - "name": "ModelRoleConfigSchema", - "fields": [ - { - "name": "ModelId", - "type_name": "ModelId", - "json_tag": "modelId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Temperature", - "type_name": "float32", - "json_tag": "temperature", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "TopP", - "type_name": "float32", - "json_tag": "topP", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "ReservedOutputTokens", - "type_name": "int", - "json_tag": "reservedOutputTokens", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "MaxConvoTokens", - "type_name": "int", - "json_tag": "maxConvoTokens", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "LargeContextFallback", - "type_name": "ModelRoleConfigSchema", - "json_tag": "largeContextFallback", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "LargeOutputFallback", - "type_name": "ModelRoleConfigSchema", - "json_tag": "largeOutputFallback", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "ErrorFallback", - "type_name": "ModelRoleConfigSchema", - "json_tag": "errorFallback", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "StrongModel", - "type_name": "ModelRoleConfigSchema", - "json_tag": "strongModel", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 311, - "is_exported": true - }, - { - "name": "PlannerRoleConfig", - "fields": [ - { - "name": "ModelRoleConfig", - "type_name": "PlannerModelConfig", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 677, - "is_exported": true - }, - { - "name": "ClientModelPackSchemaRoles", - "fields": [ - { - "name": "SchemaUrl", - "type_name": "SchemaUrl", - "json_tag": "$schema", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "LocalProvider", - "type_name": "ModelProvider", - "json_tag": "localProvider", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "in the JSON, these can either be a role as a string or a ModelRoleConfigSchema object for more complex config" - }, - { - "name": "Planner", - "type_name": "RoleJSON", - "json_tag": "planner", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Architect", - "type_name": "RoleJSON", - "json_tag": "architect", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Coder", - "type_name": "RoleJSON", - "json_tag": "coder", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PlanSummary", - "type_name": "RoleJSON", - "json_tag": "summarizer", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Builder", - "type_name": "RoleJSON", - "json_tag": "builder", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "WholeFileBuilder", - "type_name": "RoleJSON", - "json_tag": "wholeFileBuilder", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Namer", - "type_name": "RoleJSON", - "json_tag": "names", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CommitMsg", - "type_name": "RoleJSON", - "json_tag": "commitMessages", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ExecStatus", - "type_name": "RoleJSON", - "json_tag": "autoContinue", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 710, - "is_exported": true - }, - { - "name": "ModelPackSchemaRoles", - "fields": [ - { - "name": "LocalProvider", - "type_name": "ModelProvider", - "json_tag": "localProvider", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Planner", - "type_name": "ModelRoleConfigSchema", - "json_tag": "planner", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Coder", - "type_name": "ModelRoleConfigSchema", - "json_tag": "coder", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "PlanSummary", - "type_name": "ModelRoleConfigSchema", - "json_tag": "planSummary", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Builder", - "type_name": "ModelRoleConfigSchema", - "json_tag": "builder", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "WholeFileBuilder", - "type_name": "ModelRoleConfigSchema", - "json_tag": "wholeFileBuilder", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false, - "comment": "optional, defaults to builder model \u2014 access via GetWholeFileBuilder()" - }, - { - "name": "Namer", - "type_name": "ModelRoleConfigSchema", - "json_tag": "namer", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CommitMsg", - "type_name": "ModelRoleConfigSchema", - "json_tag": "commitMsg", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ExecStatus", - "type_name": "ModelRoleConfigSchema", - "json_tag": "execStatus", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Architect", - "type_name": "ModelRoleConfigSchema", - "json_tag": "contextLoader", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 797, - "is_exported": true - }, - { - "name": "ModelPackSchema", - "fields": [ - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 838, - "is_exported": true - }, - { - "name": "ModelPack", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "LocalProvider", - "type_name": "ModelProvider", - "json_tag": "localProvider", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Planner", - "type_name": "PlannerRoleConfig", - "json_tag": "planner", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Coder", - "type_name": "ModelRoleConfig", - "json_tag": "coder", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "PlanSummary", - "type_name": "ModelRoleConfig", - "json_tag": "planSummary", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Builder", - "type_name": "ModelRoleConfig", - "json_tag": "builder", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "WholeFileBuilder", - "type_name": "ModelRoleConfig", - "json_tag": "wholeFileBuilder", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false, - "comment": "optional, defaults to builder model \u2014 access via GetWholeFileBuilder()" - }, - { - "name": "Namer", - "type_name": "ModelRoleConfig", - "json_tag": "namer", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CommitMsg", - "type_name": "ModelRoleConfig", - "json_tag": "commitMsg", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ExecStatus", - "type_name": "ModelRoleConfig", - "json_tag": "execStatus", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Architect", - "type_name": "ModelRoleConfig", - "json_tag": "contextLoader", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 920, - "is_exported": true - } - ], - "enums": [ - { - "name": "ModelOutputFormat", - "type_name": "string", - "values": [ - "ModelOutputFormatToolCallJson", - "ModelOutputFormatXml" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 20 - }, - { - "name": "ReasoningEffort", - "type_name": "string", - "values": [ - "ReasoningEffortLow", - "ReasoningEffortMedium", - "ReasoningEffortHigh" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 280 - } - ], - "type_aliases": [ - { - "name": "ModelOutputFormat", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 18 - }, - { - "name": "ModelName", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 26 - }, - { - "name": "ModelId", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 27 - }, - { - "name": "ModelTag", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 28 - }, - { - "name": "VariantTag", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 29 - }, - { - "name": "ReasoningEffort", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 278 - }, - { - "name": "RoleJSON", - "underlying_type": "any", - "file_path": "/app/robot/../plandex/app/shared/ai_models_data_models.go", - "line_number": 708 - } - ] - }, - "ai_models_errors": { - "package_name": "shared", - "imports": [ - "log", - "github.com/davecgh/go-spew/spew", - "github.com/jinzhu/copier" - ], - "structs": [ - { - "name": "ModelError", - "fields": [ - { - "name": "Kind", - "type_name": "ModelErrKind", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Retriable", - "type_name": "bool", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "RetryAfterSeconds", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_errors.go", - "line_number": 21, - "is_exported": true - }, - { - "name": "FallbackResult", - "fields": [ - { - "name": "ModelRoleConfig", - "type_name": "ModelRoleConfig", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "IsFallback", - "type_name": "bool", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "FallbackType", - "type_name": "FallbackType", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "BaseModelConfig", - "type_name": "BaseModelConfig", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_errors.go", - "line_number": 40, - "is_exported": true - } - ], - "enums": [ - { - "name": "ModelErrKind", - "type_name": "string", - "values": [ - "ErrOverloaded", - "ErrContextTooLong", - "ErrRateLimited", - "ErrSubscriptionQuotaExhausted", - "ErrOther", - "ErrCacheSupport" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_errors.go", - "line_number": 12 - }, - { - "name": "FallbackType", - "type_name": "string", - "values": [ - "FallbackTypeError", - "FallbackTypeContext", - "FallbackTypeProvider" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_errors.go", - "line_number": 34 - } - ], - "type_aliases": [ - { - "name": "ModelErrKind", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_errors.go", - "line_number": 10 - }, - { - "name": "FallbackType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_errors.go", - "line_number": 32 - } - ] - }, - "ai_models_openrouter": { - "package_name": "shared", - "imports": [], - "structs": [], - "enums": [ - { - "name": "OpenRouterFamily", - "type_name": "string", - "values": [ - "OpenRouterFamilyAnthropic", - "OpenRouterFamilyGoogle", - "OpenRouterFamilyOpenAI", - "OpenRouterFamilyQwen", - "OpenRouterFamilyDeepSeek" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_openrouter.go", - "line_number": 5 - } - ], - "type_aliases": [ - { - "name": "OpenRouterFamily", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_openrouter.go", - "line_number": 3 - } - ] - }, - "ai_models_providers": { - "package_name": "shared", - "imports": [ - "fmt" - ], - "structs": [ - { - "name": "ModelProviderExtraAuthVars", - "fields": [ - { - "name": "Var", - "type_name": "string", - "json_tag": "var", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MaybeJSONFilePath", - "type_name": "bool", - "json_tag": "maybeJSONFilePath", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Required", - "type_name": "bool", - "json_tag": "required", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Default", - "type_name": "string", - "json_tag": "default", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_providers.go", - "line_number": 79, - "is_exported": true - }, - { - "name": "ModelProviderConfigSchema", - "fields": [ - { - "name": "Provider", - "type_name": "ModelProvider", - "json_tag": "provider", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CustomProvider", - "type_name": "string", - "json_tag": "customProvider", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "BaseUrl", - "type_name": "string", - "json_tag": "baseUrl", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "for AWS Bedrock models" - }, - { - "name": "HasAWSAuth", - "type_name": "bool", - "json_tag": "hasAWSAuth", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "for Claude Max integration" - }, - { - "name": "HasClaudeMaxAuth", - "type_name": "bool", - "json_tag": "hasClaudeMaxAuth", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "for local models that don't require auth (ollama, etc.)" - }, - { - "name": "SkipAuth", - "type_name": "bool", - "json_tag": "skipAuth", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "LocalOnly", - "type_name": "bool", - "json_tag": "localOnly", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ApiKeyEnvVar", - "type_name": "string", - "json_tag": "apiKeyEnvVar", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ExtraAuthVars", - "type_name": "ModelProviderExtraAuthVars", - "json_tag": "extraAuthVars", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_providers.go", - "line_number": 86, - "is_exported": true - } - ], - "enums": [ - { - "name": "ModelPublisher", - "type_name": "string", - "values": [ - "ModelPublisherOpenAI", - "ModelPublisherAnthropic", - "ModelPublisherGoogle", - "ModelPublisherDeepSeek", - "ModelPublisherPerplexity", - "ModelPublisherQwen", - "ModelPublisherMistral" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_providers.go", - "line_number": 26 - }, - { - "name": "ModelProvider", - "type_name": "string", - "values": [ - "ModelProviderOpenRouter", - "ModelProviderOpenAI", - "ModelProviderAnthropic", - "ModelProviderAnthropicClaudeMax", - "ModelProviderGoogleAIStudio", - "ModelProviderGoogleVertex", - "ModelProviderAzureOpenAI", - "ModelProviderDeepSeek", - "ModelProviderPerplexity", - "ModelProviderAmazonBedrock", - "ModelProviderOllama", - "ModelProviderCustom" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_providers.go", - "line_number": 38 - } - ], - "type_aliases": [ - { - "name": "ModelPublisher", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_providers.go", - "line_number": 24 - }, - { - "name": "ModelProvider", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_providers.go", - "line_number": 36 - } - ] - }, - "ai_models_roles": { - "package_name": "shared", - "imports": [], - "structs": [], - "enums": [ - { - "name": "ModelRole", - "type_name": "string", - "values": [ - "ModelRolePlanner", - "ModelRoleCoder", - "ModelRoleArchitect", - "ModelRolePlanSummary", - "ModelRoleBuilder", - "ModelRoleWholeFileBuilder", - "ModelRoleName", - "ModelRoleCommitMsg", - "ModelRoleExecStatus" - ], - "file_path": "/app/robot/../plandex/app/shared/ai_models_roles.go", - "line_number": 5 - } - ], - "type_aliases": [ - { - "name": "ModelRole", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/ai_models_roles.go", - "line_number": 3 - } - ] - }, - "auth": { - "package_name": "shared", - "imports": [ - "crypto/sha256", - "encoding/hex", - "fmt", - "strconv", - "strings" - ], - "structs": [ - { - "name": "AuthHeader", - "fields": [ - { - "name": "Token", - "type_name": "string", - "json_tag": "token", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgId", - "type_name": "string", - "json_tag": "orgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Hash", - "type_name": "string", - "json_tag": "hash", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 11, - "is_exported": true - }, - { - "name": "TrialPlansExceededError", - "fields": [ - { - "name": "MaxPlans", - "type_name": "int", - "json_tag": "maxPlans", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 36, - "is_exported": true - }, - { - "name": "TrialMessagesExceededError", - "fields": [ - { - "name": "MaxReplies", - "type_name": "int", - "json_tag": "maxMessages", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 40, - "is_exported": true - }, - { - "name": "BillingError", - "fields": [ - { - "name": "HasBillingPermission", - "type_name": "bool", - "json_tag": "hasBillingPermission", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsTrial", - "type_name": "bool", - "json_tag": "isTrial", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 44, - "is_exported": true - }, - { - "name": "ApiError", - "fields": [ - { - "name": "Type", - "type_name": "ApiErrorType", - "json_tag": "type", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Status", - "type_name": "int", - "json_tag": "status", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Msg", - "type_name": "string", - "json_tag": "msg", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "only used for trial plans exceeded error" - }, - { - "name": "TrialPlansExceededError", - "type_name": "TrialPlansExceededError", - "json_tag": "trialPlansExceededError", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false, - "comment": "only used for trial messages exceeded error" - }, - { - "name": "TrialMessagesExceededError", - "type_name": "TrialMessagesExceededError", - "json_tag": "trialMessagesExceededError", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false, - "comment": "only used for billing errors" - }, - { - "name": "BillingError", - "type_name": "BillingError", - "json_tag": "billingError", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 49, - "is_exported": true - }, - { - "name": "ClientAccount", - "fields": [ - { - "name": "IsCloud", - "type_name": "bool", - "json_tag": "isCloud", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Host", - "type_name": "string", - "json_tag": "host", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserName", - "type_name": "string", - "json_tag": "userName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserId", - "type_name": "string", - "json_tag": "userId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Token", - "type_name": "string", - "json_tag": "token", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsLocalMode", - "type_name": "bool", - "json_tag": "isLocalMode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsTrial", - "type_name": "bool", - "json_tag": "isTrial", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "legacy field" - } - ], - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 68, - "is_exported": true - }, - { - "name": "ClientAuth", - "fields": [ - { - "name": "OrgId", - "type_name": "string", - "json_tag": "orgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgName", - "type_name": "string", - "json_tag": "orgName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgIsTrial", - "type_name": "bool", - "json_tag": "orgIsTrial", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IntegratedModelsMode", - "type_name": "bool", - "json_tag": "integratedModelsMode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 80, - "is_exported": true - } - ], - "enums": [ - { - "name": "ApiErrorType", - "type_name": "string", - "values": [ - "ApiErrorTypeInvalidToken", - "ApiErrorTypeAuthOutdated", - "ApiErrorTypeTrialPlansExceeded", - "ApiErrorTypeTrialMessagesExceeded", - "ApiErrorTypeTrialActionNotAllowed", - "ApiErrorTypeContinueNoMessages", - "ApiErrorTypeCloudInsufficientCredits", - "ApiErrorTypeCloudMonthlyMaxReached", - "ApiErrorTypeCloudSubscriptionPaused", - "ApiErrorTypeCloudSubscriptionOverdue", - "ApiErrorTypeOther" - ], - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 19 - } - ], - "type_aliases": [ - { - "name": "ApiErrorType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/auth.go", - "line_number": 17 - } - ] - }, - "context": { - "package_name": "shared", - "imports": [ - "fmt", - "math", - "strconv", - "strings", - "github.com/olekukonko/tablewriter" - ], - "structs": [ - { - "name": "ContextUpdateResult", - "fields": [ - { - "name": "UpdatedContexts", - "type_name": "*Context", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "TokenDiffsById", - "type_name": "map[string]int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "TokensDiff", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TotalTokens", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumFiles", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumUrls", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumImages", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumTrees", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumMaps", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MaxTokens", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/context.go", - "line_number": 24, - "is_exported": true - }, - { - "name": "SummaryForUpdateContextParams", - "fields": [ - { - "name": "NumFiles", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumTrees", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumUrls", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumMaps", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TokensDiff", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TotalTokens", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/context.go", - "line_number": 237, - "is_exported": true - } - ], - "enums": [ - { - "name": "MaxContextCount", - "type_name": "string", - "values": [ - "25MB" - ], - "file_path": "/app/robot/../plandex/app/shared/context.go", - "line_number": 12 - } - ], - "type_aliases": [] - }, - "data_models": { - "package_name": "shared", - "imports": [ - "time", - "github.com/sashabaranov/go-openai", - "github.com/shopspring/decimal" - ], - "structs": [ - { - "name": "Org", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsTrial", - "type_name": "bool", - "json_tag": "isTrial", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoAddDomainUsers", - "type_name": "bool", - "json_tag": "autoAddDomainUsers", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "optional cloud attributes" - }, - { - "name": "IntegratedModelsMode", - "type_name": "bool", - "json_tag": "integratedModelsMode", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CloudBillingFields", - "type_name": "CloudBillingFields", - "json_tag": "cloudBillingFields", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 10, - "is_exported": true - }, - { - "name": "User", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsTrial", - "type_name": "bool", - "json_tag": "isTrial", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumNonDraftPlans", - "type_name": "int", - "json_tag": "numNonDraftPlans", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DefaultPlanConfig", - "type_name": "PlanConfig", - "json_tag": "defaultPlanConfig", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 21, - "is_exported": true - }, - { - "name": "OrgUser", - "fields": [ - { - "name": "OrgId", - "type_name": "string", - "json_tag": "orgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserId", - "type_name": "string", - "json_tag": "userId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgRoleId", - "type_name": "string", - "json_tag": "orgRoleId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Config", - "type_name": "OrgUserConfig", - "json_tag": "config", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 31, - "is_exported": true - }, - { - "name": "Invite", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgId", - "type_name": "string", - "json_tag": "orgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgRoleId", - "type_name": "string", - "json_tag": "orgRoleId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "InviterId", - "type_name": "string", - "json_tag": "inviterId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "InviteeId", - "type_name": "string", - "json_tag": "inviteeId", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "AcceptedAt", - "type_name": "time.Time", - "json_tag": "acceptedAt", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 39, - "is_exported": true - }, - { - "name": "Project", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 51, - "is_exported": true - }, - { - "name": "Plan", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OwnerId", - "type_name": "string", - "json_tag": "ownerId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ProjectId", - "type_name": "string", - "json_tag": "projectId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SharedWithOrgAt", - "type_name": "time.Time", - "json_tag": "sharedWithOrgAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "TotalReplies", - "type_name": "int", - "json_tag": "totalReplies", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ActiveBranches", - "type_name": "int", - "json_tag": "activeBranches", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PlanConfig", - "type_name": "PlanConfig", - "json_tag": "planConfig", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "ArchivedAt", - "type_name": "time.Time", - "json_tag": "archivedAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 56, - "is_exported": true - }, - { - "name": "Branch", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PlanId", - "type_name": "string", - "json_tag": "planId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OwnerId", - "type_name": "string", - "json_tag": "ownerId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ParentBranchId", - "type_name": "string", - "json_tag": "parentBranchId", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Status", - "type_name": "PlanStatus", - "json_tag": "status", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ContextTokens", - "type_name": "int", - "json_tag": "contextTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ConvoTokens", - "type_name": "int", - "json_tag": "convoTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SharedWithOrgAt", - "type_name": "time.Time", - "json_tag": "sharedWithOrgAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "ArchivedAt", - "type_name": "time.Time", - "json_tag": "archivedAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 70, - "is_exported": true - }, - { - "name": "Context", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OwnerId", - "type_name": "string", - "json_tag": "ownerId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ContextType", - "type_name": "ContextType", - "json_tag": "contextType", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Url", - "type_name": "string", - "json_tag": "url", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "FilePath", - "type_name": "string", - "json_tag": "file_path", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Sha", - "type_name": "string", - "json_tag": "sha", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumTokens", - "type_name": "int", - "json_tag": "numTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Body", - "type_name": "string", - "json_tag": "body", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "BodySize", - "type_name": "int64", - "json_tag": "bodySize", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ForceSkipIgnore", - "type_name": "bool", - "json_tag": "forceSkipIgnore", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ImageDetail", - "type_name": "openai.ImageURLDetail", - "json_tag": "imageDetail", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MapParts", - "type_name": "FileMapBodies", - "json_tag": "mapParts", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MapShas", - "type_name": "map[string]string", - "json_tag": "mapShas", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "MapTokens", - "type_name": "map[string]int", - "json_tag": "mapTokens", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "MapSizes", - "type_name": "map[string]int64", - "json_tag": "mapSizes", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "AutoLoaded", - "type_name": "bool", - "json_tag": "autoLoaded", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 99, - "is_exported": true - }, - { - "name": "CurrentStage", - "fields": [ - { - "name": "TellStage", - "type_name": "TellStage", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PlanningPhase", - "type_name": "PlanningPhase", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 135, - "is_exported": true - }, - { - "name": "ConvoMessageFlags", - "fields": [ - { - "name": "DidMakePlan", - "type_name": "bool", - "json_tag": "didMakePlan", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DidRemoveTasks", - "type_name": "bool", - "json_tag": "didRemoveTasks", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DidMakeDebuggingPlan", - "type_name": "bool", - "json_tag": "didMakeDebuggingPlan", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DidLoadContext", - "type_name": "bool", - "json_tag": "didLoadContext", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CurrentStage", - "type_name": "CurrentStage", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsChat", - "type_name": "bool", - "json_tag": "isChat", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DidWriteCode", - "type_name": "bool", - "json_tag": "didWriteCode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DidCompleteTask", - "type_name": "bool", - "json_tag": "didCompleteTask", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DidCompletePlan", - "type_name": "bool", - "json_tag": "didCompletePlan", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "HasUnfinishedSubtasks", - "type_name": "bool", - "json_tag": "hasUnfinishedSubtasks", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsApplyDebug", - "type_name": "bool", - "json_tag": "isApplyDebug", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsUserDebug", - "type_name": "bool", - "json_tag": "isUserDebug", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "HasError", - "type_name": "bool", - "json_tag": "hasError", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 140, - "is_exported": true - }, - { - "name": "Subtask", - "fields": [ - { - "name": "Title", - "type_name": "string", - "json_tag": "title", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UsesFiles", - "type_name": "string", - "json_tag": "usesFiles", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "IsFinished", - "type_name": "bool", - "json_tag": "isFinished", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 156, - "is_exported": true - }, - { - "name": "ConvoMessage", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserId", - "type_name": "string", - "json_tag": "userId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Role", - "type_name": "string", - "json_tag": "role", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Tokens", - "type_name": "int", - "json_tag": "tokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Num", - "type_name": "int", - "json_tag": "num", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Message", - "type_name": "string", - "json_tag": "message", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Stopped", - "type_name": "bool", - "json_tag": "stopped", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Flags", - "type_name": "ConvoMessageFlags", - "json_tag": "flags", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Subtask", - "type_name": "Subtask", - "json_tag": "subtask", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "AddedSubtasks", - "type_name": "*Subtask", - "json_tag": "addedSubtasks", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "RemovedSubtasks", - "type_name": "string", - "json_tag": "removedSubtasks", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "ActiveContextIds", - "type_name": "string", - "json_tag": "activeContextIds", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 163, - "is_exported": true - }, - { - "name": "ConvoSummary", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "LatestConvoMessageCreatedAt", - "type_name": "time.Time", - "json_tag": "latestConvoMessageCreatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "LatestConvoMessageId", - "type_name": "string", - "json_tag": "lastestConvoMessageId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Summary", - "type_name": "string", - "json_tag": "summary", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Tokens", - "type_name": "int", - "json_tag": "tokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumMessages", - "type_name": "int", - "json_tag": "numMessages", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 179, - "is_exported": true - }, - { - "name": "Operation", - "fields": [ - { - "name": "Type", - "type_name": "OperationType", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Path", - "type_name": "string", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Destination", - "type_name": "string", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Content", - "type_name": "string", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ReplyBefore", - "type_name": "string", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumTokens", - "type_name": "int", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 198, - "is_exported": true - }, - { - "name": "ConvoMessageDescription", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ConvoMessageId", - "type_name": "string", - "json_tag": "convoMessageId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SummarizedToMessageId", - "type_name": "string", - "json_tag": "summarizedToMessageId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "WroteFiles", - "type_name": "bool", - "json_tag": "wroteFiles", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CommitMsg", - "type_name": "string", - "json_tag": "commitMsg", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "Files []string" - }, - { - "name": "Operations", - "type_name": "*Operation", - "json_tag": "operations", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "DidBuild", - "type_name": "bool", - "json_tag": "didBuild", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "BuildPathsInvalidated", - "type_name": "map[string]bool", - "json_tag": "buildPathsInvalidated", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "Error", - "type_name": "string", - "json_tag": "error", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AppliedAt", - "type_name": "time.Time", - "json_tag": "appliedAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 216, - "is_exported": true - }, - { - "name": "PlanBuild", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ConvoMessageId", - "type_name": "string", - "json_tag": "convoMessageId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "FilePath", - "type_name": "string", - "json_tag": "filePath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Error", - "type_name": "string", - "json_tag": "error", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 232, - "is_exported": true - }, - { - "name": "Replacement", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Old", - "type_name": "string", - "json_tag": "old", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Summary", - "type_name": "string", - "json_tag": "summary", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "EntireFile", - "type_name": "bool", - "json_tag": "entireFile", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "New", - "type_name": "string", - "json_tag": "new", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Failed", - "type_name": "bool", - "json_tag": "failed", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "RejectedAt", - "type_name": "time.Time", - "json_tag": "rejectedAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "StreamedChange", - "type_name": "StreamedChangeWithLineNums", - "json_tag": "streamedChange", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 241, - "is_exported": true - }, - { - "name": "PlanFileResult", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TypeVersion", - "type_name": "int", - "json_tag": "typeVersion", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ReplaceWithLineNums", - "type_name": "bool", - "json_tag": "replaceWithLineNums", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ConvoMessageId", - "type_name": "string", - "json_tag": "convoMessageId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PlanBuildId", - "type_name": "string", - "json_tag": "planBuildId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Path", - "type_name": "string", - "json_tag": "path", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Content", - "type_name": "string", - "json_tag": "content", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AnyFailed", - "type_name": "bool", - "json_tag": "anyFailed", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AppliedAt", - "type_name": "time.Time", - "json_tag": "appliedAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "RejectedAt", - "type_name": "time.Time", - "json_tag": "rejectedAt", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "Replacements", - "type_name": "*Replacement", - "json_tag": "replacements", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "RemovedFile", - "type_name": "bool", - "json_tag": "removedFile", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 252, - "is_exported": true - }, - { - "name": "CurrentPlanFiles", - "fields": [ - { - "name": "Files", - "type_name": "map[string]string", - "json_tag": "files", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "Removed", - "type_name": "map[string]bool", - "json_tag": "removedByPath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "UpdatedAtByPath", - "type_name": "map[string]time.Time", - "json_tag": "updatedAtByPath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 271, - "is_exported": true - }, - { - "name": "PlanResult", - "fields": [ - { - "name": "SortedPaths", - "type_name": "string", - "json_tag": "sortedPaths", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "FileResultsByPath", - "type_name": "PlanFileResultsByPath", - "json_tag": "fileResultsByPath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Results", - "type_name": "*PlanFileResult", - "json_tag": "results", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "ReplacementsByPath", - "type_name": "map[string][]*Replacement", - "json_tag": "replacementsByPath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 278, - "is_exported": true - }, - { - "name": "PlanApply", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserId", - "type_name": "string", - "json_tag": "userId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ConvoMessageIds", - "type_name": "string", - "json_tag": "convoMessageIds", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "ConvoMessageDescriptionIds", - "type_name": "string", - "json_tag": "convoMessageDescriptionIds", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "PlanFileResultIds", - "type_name": "string", - "json_tag": "planFileResultIds", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CommitMsg", - "type_name": "string", - "json_tag": "commitMsg", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 285, - "is_exported": true - }, - { - "name": "CurrentPlanState", - "fields": [ - { - "name": "PlanResult", - "type_name": "PlanResult", - "json_tag": "planResult", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CurrentPlanFiles", - "type_name": "CurrentPlanFiles", - "json_tag": "currentPlanFiles", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "ConvoMessageDescriptions", - "type_name": "*ConvoMessageDescription", - "json_tag": "convoMessageDescriptions", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "PlanApplies", - "type_name": "*PlanApply", - "json_tag": "planApplies", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "ContextsByPath", - "type_name": "map[string]*Context", - "json_tag": "contextsByPath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 295, - "is_exported": true - }, - { - "name": "OrgRole", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsDefault", - "type_name": "bool", - "json_tag": "isDefault", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Label", - "type_name": "string", - "json_tag": "label", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "string", - "json_tag": "description", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 303, - "is_exported": true - }, - { - "name": "CloudBillingFields", - "fields": [ - { - "name": "CreditsBalance", - "type_name": "decimal.Decimal", - "json_tag": "creditsBalance", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MonthlyGrant", - "type_name": "decimal.Decimal", - "json_tag": "monthlyGrant", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoRebuyEnabled", - "type_name": "bool", - "json_tag": "autoRebuyEnabled", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoRebuyMinThreshold", - "type_name": "decimal.Decimal", - "json_tag": "autoRebuyMinThreshold", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoRebuyToBalance", - "type_name": "decimal.Decimal", - "json_tag": "autoRebuyToBalance", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NotifyThreshold", - "type_name": "decimal.Decimal", - "json_tag": "notifyThreshold", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MaxThresholdPerMonth", - "type_name": "decimal.Decimal", - "json_tag": "maxThresholdPerMonth", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "BillingCycleStartedAt", - "type_name": "time.Time", - "json_tag": "billingCycleStartedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ChangedBillingMode", - "type_name": "bool", - "json_tag": "changedBillingMode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TrialPaid", - "type_name": "bool", - "json_tag": "trialPaid", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "StripeSubscriptionId", - "type_name": "string", - "json_tag": "stripeSubscriptionId", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "SubscriptionStatus", - "type_name": "string", - "json_tag": "subscriptionStatus", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "SubscriptionPausedAt", - "type_name": "time.Time", - "json_tag": "subscriptionPausedAt", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "StripePaymentMethod", - "type_name": "string", - "json_tag": "stripePaymentMethod", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "SubscriptionActionRequired", - "type_name": "bool", - "json_tag": "subscriptionActionRequired", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "for 3ds/sca approvals" - }, - { - "name": "SubscriptionActionRequiredInvoiceUrl", - "type_name": "string", - "json_tag": "subscriptionActionRequiredInvoiceUrl", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 310, - "is_exported": true - }, - { - "name": "CreditsTransaction", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgId", - "type_name": "string", - "json_tag": "orgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgName", - "type_name": "string", - "json_tag": "orgName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserId", - "type_name": "string", - "json_tag": "userId", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "UserEmail", - "type_name": "string", - "json_tag": "userEmail", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "UserName", - "type_name": "string", - "json_tag": "userName", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "TransactionType", - "type_name": "CreditsTransactionType", - "json_tag": "transactionType", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Amount", - "type_name": "decimal.Decimal", - "json_tag": "amount", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "StartBalance", - "type_name": "decimal.Decimal", - "json_tag": "startBalance", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "EndBalance", - "type_name": "decimal.Decimal", - "json_tag": "endBalance", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CreditType", - "type_name": "CreditType", - "json_tag": "creditType", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CreditIsAutoRebuy", - "type_name": "bool", - "json_tag": "creditIsAutoRebuy", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CreditAutoRebuyMinThreshold", - "type_name": "decimal.Decimal", - "json_tag": "creditAutoRebuyMinThreshold", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CreditAutoRebuyToBalance", - "type_name": "decimal.Decimal", - "json_tag": "creditAutoRebuyToBalance", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitInputTokens", - "type_name": "int", - "json_tag": "debitInputTokens", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitOutputTokens", - "type_name": "int", - "json_tag": "debitOutputTokens", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitModelInputPricePerToken", - "type_name": "decimal.Decimal", - "json_tag": "debitModelInputPricePerToken", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitModelOutputPricePerToken", - "type_name": "decimal.Decimal", - "json_tag": "debitModelOutputPricePerToken", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitBaseAmount", - "type_name": "decimal.Decimal", - "json_tag": "debitBaseAmount", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitSurcharge", - "type_name": "decimal.Decimal", - "json_tag": "debitSurcharge", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitModelProvider", - "type_name": "ModelProvider", - "json_tag": "debitModelProvider", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitModelName", - "type_name": "string", - "json_tag": "debitModelName", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitModelPackName", - "type_name": "string", - "json_tag": "debitModelPackName", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitModelRole", - "type_name": "ModelRole", - "json_tag": "debitModelRole", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitPurpose", - "type_name": "string", - "json_tag": "debitPurpose", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitPlanId", - "type_name": "string", - "json_tag": "debitPlanId", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitPlanName", - "type_name": "string", - "json_tag": "debitPlanName", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitId", - "type_name": "string", - "json_tag": "debitId", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitCacheDiscount", - "type_name": "decimal.Decimal", - "json_tag": "debitCacheDiscount", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "DebitSessionId", - "type_name": "string", - "json_tag": "debitSessionId", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CreatedAt", - "type_name": "time.Time", - "json_tag": "createdAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 348, - "is_exported": true - } - ], - "enums": [ - { - "name": "ContextType", - "type_name": "string", - "values": [ - "ContextFileType", - "ContextURLType", - "ContextNoteType", - "ContextDirectoryTreeType", - "ContextPipedDataType", - "ContextImageType", - "ContextMapType" - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 87 - }, - { - "name": "TellStage", - "type_name": "string", - "values": [ - "TellStagePlanning", - "TellStageImplementation" - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 123 - }, - { - "name": "PlanningPhase", - "type_name": "string", - "values": [ - "PlanningPhaseContext", - "PlanningPhaseTasks" - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 130 - }, - { - "name": "OperationType", - "type_name": "string", - "values": [ - "OperationTypeFile", - "OperationTypeMove", - "OperationTypeRemove", - "OperationTypeReset" - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 191 - }, - { - "name": "CreditsTransactionType", - "type_name": "string", - "values": [ - "CreditsTransactionTypeCredit", - "CreditsTransactionTypeDebit" - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 333 - }, - { - "name": "CreditType", - "type_name": "string", - "values": [ - "CreditTypeTrial", - "CreditTypeGrant", - "CreditTypeAdminGrant", - "CreditTypePurchase", - "CreditTypeSwitch" - ], - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 340 - } - ], - "type_aliases": [ - { - "name": "ContextType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 85 - }, - { - "name": "FileMapBodies", - "underlying_type": "map[string]string", - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 97 - }, - { - "name": "TellStage", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 121 - }, - { - "name": "PlanningPhase", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 128 - }, - { - "name": "OperationType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 189 - }, - { - "name": "PlanFileResultsByPath", - "underlying_type": "map[string][]*PlanFileResult", - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 277 - }, - { - "name": "CreditsTransactionType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 331 - }, - { - "name": "CreditType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/data_models.go", - "line_number": 338 - } - ] - }, - "org_user_config": { - "package_name": "shared", - "imports": [ - "database/sql/driver", - "encoding/json", - "fmt", - "time" - ], - "structs": [ - { - "name": "OrgUserConfig", - "fields": [ - { - "name": "PromptedClaudeMax", - "type_name": "bool", - "json_tag": "promptedClaudeMax", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UseClaudeSubscription", - "type_name": "bool", - "json_tag": "useClaudeSubscription", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ClaudeSubscriptionCooldownStartedAt", - "type_name": "time.Time", - "json_tag": "claudeSubscriptionCooldownStartedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/org_user_config.go", - "line_number": 14, - "is_exported": true - } - ], - "enums": [], - "type_aliases": [] - }, - "plan_config": { - "package_name": "shared", - "imports": [ - "database/sql/driver", - "encoding/json", - "fmt", - "strings" - ], - "structs": [ - { - "name": "PlanConfig", - "fields": [ - { - "name": "AutoMode", - "type_name": "AutoModeType", - "json_tag": "autoMode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "QuietMode bool" - }, - { - "name": "Editor", - "type_name": "string", - "json_tag": "editor", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "EditorCommand", - "type_name": "string", - "json_tag": "editorCommand", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "EditorArgs", - "type_name": "string", - "json_tag": "editorArgs", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "EditorOpenManually", - "type_name": "bool", - "json_tag": "editorOpenManually", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoContinue", - "type_name": "bool", - "json_tag": "autoContinue", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoBuild", - "type_name": "bool", - "json_tag": "autoBuild", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoUpdateContext", - "type_name": "bool", - "json_tag": "autoUpdateContext", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoLoadContext", - "type_name": "bool", - "json_tag": "autoContext", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SmartContext", - "type_name": "bool", - "json_tag": "smartContext", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "AutoApproveContext bool" - }, - { - "name": "AutoApply", - "type_name": "bool", - "json_tag": "autoApply", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoCommit", - "type_name": "bool", - "json_tag": "autoCommit", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SkipCommit", - "type_name": "bool", - "json_tag": "skipCommit", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "CanExec", - "type_name": "bool", - "json_tag": "canExec", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoExec", - "type_name": "bool", - "json_tag": "autoExec", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoDebug", - "type_name": "bool", - "json_tag": "autoDebug", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoDebugTries", - "type_name": "int", - "json_tag": "autoDebugTries", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoRevertOnRewind", - "type_name": "bool", - "json_tag": "autoRevertOnRewind", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SkipChangesMenu", - "type_name": "bool", - "json_tag": "skipChangesMenu", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "ReplMode bool" - } - ], - "file_path": "/app/robot/../plandex/app/shared/plan_config.go", - "line_number": 53, - "is_exported": true - }, - { - "name": "ConfigSetting", - "fields": [ - { - "name": "Name", - "type_name": "string", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Desc", - "type_name": "string", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Choices", - "type_name": "string", - "omitempty": false, - "is_optional": true, - "is_array": true, - "is_map": false - }, - { - "name": "HasCustomChoice", - "type_name": "bool", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SortKey", - "type_name": "string", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/plan_config.go", - "line_number": 205, - "is_exported": true - } - ], - "enums": [ - { - "name": "string", - "type_name": "string", - "values": [ - "EditorTypeVim", - "EditorTypeNano" - ], - "file_path": "/app/robot/../plandex/app/shared/plan_config.go", - "line_number": 12 - }, - { - "name": "AutoModeType", - "type_name": "string", - "values": [ - "AutoModeFull", - "AutoModeSemi", - "AutoModePlus", - "AutoModeBasic", - "AutoModeNone", - "AutoModeCustom" - ], - "file_path": "/app/robot/../plandex/app/shared/plan_config.go", - "line_number": 21 - } - ], - "type_aliases": [ - { - "name": "AutoModeType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/plan_config.go", - "line_number": 19 - } - ] - }, - "plan_model_settings": { - "package_name": "shared", - "imports": [ - "database/sql/driver", - "encoding/json", - "fmt", - "time" - ], - "structs": [ - { - "name": "PlanSettings", - "fields": [ - { - "name": "ModelPackName", - "type_name": "string", - "json_tag": "modelPackName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ModelPack", - "type_name": "ModelPack", - "json_tag": "modelPack", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CustomModelPacks", - "type_name": "*ModelPack", - "json_tag": "customModelPacks", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CustomModels", - "type_name": "*CustomModel", - "json_tag": "customModels", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "CustomModelsById", - "type_name": "map[ModelId]*CustomModel", - "json_tag": "customModelsById", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "CustomProviders", - "type_name": "*CustomProvider", - "json_tag": "customProviders", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "UsesCustomProviderByModelId", - "type_name": "map[ModelId][]BaseModelUsesProvider", - "json_tag": "usesCustomProviderByModelId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "IsCloud", - "type_name": "bool", - "json_tag": "isCloud", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Configured", - "type_name": "bool", - "json_tag": "configured", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UpdatedAt", - "type_name": "time.Time", - "json_tag": "updatedAt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/plan_model_settings.go", - "line_number": 10, - "is_exported": true - } - ], - "enums": [], - "type_aliases": [] - }, - "plan_status": { - "package_name": "shared", - "imports": [], - "structs": [], - "enums": [ - { - "name": "PlanStatus", - "type_name": "string", - "values": [ - "PlanStatusDraft", - "PlanStatusReplying", - "PlanStatusDescribing", - "PlanStatusBuilding", - "PlanStatusMissingFile", - "PlanStatusFinished", - "PlanStatusStopped", - "PlanStatusError" - ], - "file_path": "/app/robot/../plandex/app/shared/plan_status.go", - "line_number": 5 - } - ], - "type_aliases": [ - { - "name": "PlanStatus", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/plan_status.go", - "line_number": 3 - } - ] - }, - "rbac": { - "package_name": "shared", - "imports": [ - "strings" - ], - "structs": [], - "enums": [ - { - "name": "Permission", - "type_name": "string", - "values": [ - "PermissionDeleteOrg", - "PermissionManageEmailDomainAuth", - "PermissionManageBilling", - "PermissionInviteUser", - "PermissionRemoveUser", - "PermissionSetUserRole", - "PermissionListOrgRoles", - "PermissionCreateProject", - "PermissionRenameAnyProject", - "PermissionDeleteAnyProject", - "PermissionCreatePlan", - "PermissionManageAnyPlanShares", - "PermissionRenameAnyPlan", - "PermissionDeleteAnyPlan", - "PermissionUpdateAnyPlan", - "PermissionArchiveAnyPlan" - ], - "file_path": "/app/robot/../plandex/app/shared/rbac.go", - "line_number": 9 - } - ], - "type_aliases": [ - { - "name": "Permission", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/rbac.go", - "line_number": 7 - }, - { - "name": "Permissions", - "underlying_type": "map[string]bool", - "file_path": "/app/robot/../plandex/app/shared/rbac.go", - "line_number": 28 - } - ] - }, - "req_res": { - "package_name": "shared", - "imports": [ - "time", - "github.com/sashabaranov/go-openai", - "github.com/shopspring/decimal" - ], - "structs": [ - { - "name": "CreateEmailVerificationRequest", - "fields": [ - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserId", - "type_name": "string", - "json_tag": "userId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "RequireUser", - "type_name": "bool", - "json_tag": "requireUser", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "RequireNoUser", - "type_name": "bool", - "json_tag": "requireNoUser", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 10, - "is_exported": true - }, - { - "name": "CreateEmailVerificationResponse", - "fields": [ - { - "name": "HasAccount", - "type_name": "bool", - "json_tag": "hasAccount", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsLocalMode", - "type_name": "bool", - "json_tag": "isLocalMode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 17, - "is_exported": true - }, - { - "name": "VerifyEmailPinRequest", - "fields": [ - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Pin", - "type_name": "string", - "json_tag": "pin", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 22, - "is_exported": true - }, - { - "name": "SignInRequest", - "fields": [ - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Pin", - "type_name": "string", - "json_tag": "pin", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsSignInCode", - "type_name": "bool", - "json_tag": "isSignInCode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 27, - "is_exported": true - }, - { - "name": "UiSignInToken", - "fields": [ - { - "name": "Pin", - "type_name": "string", - "json_tag": "pin", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "RedirectTo", - "type_name": "string", - "json_tag": "redirectTo", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 33, - "is_exported": true - }, - { - "name": "CreateAccountRequest", - "fields": [ - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Pin", - "type_name": "string", - "json_tag": "pin", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserName", - "type_name": "string", - "json_tag": "userName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 38, - "is_exported": true - }, - { - "name": "SessionResponse", - "fields": [ - { - "name": "UserId", - "type_name": "string", - "json_tag": "userId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Token", - "type_name": "string", - "json_tag": "token", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserName", - "type_name": "string", - "json_tag": "userName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Orgs", - "type_name": "*Org", - "json_tag": "orgs", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "IsLocalMode", - "type_name": "bool", - "json_tag": "isLocalMode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 44, - "is_exported": true - }, - { - "name": "CreateOrgRequest", - "fields": [ - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoAddDomainUsers", - "type_name": "bool", - "json_tag": "autoAddDomainUsers", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 53, - "is_exported": true - }, - { - "name": "ConvertTrialRequest", - "fields": [ - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Pin", - "type_name": "string", - "json_tag": "pin", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "UserName", - "type_name": "string", - "json_tag": "userName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgName", - "type_name": "string", - "json_tag": "orgName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgAutoAddDomainUsers", - "type_name": "bool", - "json_tag": "orgAutoAddDomainUsers", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 58, - "is_exported": true - }, - { - "name": "CreateOrgResponse", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 66, - "is_exported": true - }, - { - "name": "InviteRequest", - "fields": [ - { - "name": "Email", - "type_name": "string", - "json_tag": "email", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OrgRoleId", - "type_name": "string", - "json_tag": "orgRoleId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 70, - "is_exported": true - }, - { - "name": "CreateProjectRequest", - "fields": [ - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 76, - "is_exported": true - }, - { - "name": "CreateProjectResponse", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 80, - "is_exported": true - }, - { - "name": "SetProjectPlanRequest", - "fields": [ - { - "name": "PlanId", - "type_name": "string", - "json_tag": "planId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 84, - "is_exported": true - }, - { - "name": "RenameProjectRequest", - "fields": [ - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 88, - "is_exported": true - }, - { - "name": "CreatePlanRequest", - "fields": [ - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 92, - "is_exported": true - }, - { - "name": "CreatePlanResponse", - "fields": [ - { - "name": "Id", - "type_name": "string", - "json_tag": "id", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 96, - "is_exported": true - }, - { - "name": "GetCurrentBranchByPlanIdRequest", - "fields": [ - { - "name": "CurrentBranchByPlanId", - "type_name": "map[string]string", - "json_tag": "currentBranchByPlanId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 101, - "is_exported": true - }, - { - "name": "ListPlansRunningResponse", - "fields": [ - { - "name": "Branches", - "type_name": "*Branch", - "json_tag": "branches", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "StreamStartedAtByBranchId", - "type_name": "map[string]time.Time", - "json_tag": "streamStartedAtByBranchId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "StreamFinishedAtByBranchId", - "type_name": "map[string]time.Time", - "json_tag": "streamFinishedAtByBranchId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "StreamIdByBranchId", - "type_name": "map[string]string", - "json_tag": "streamIdByBranchId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "PlansById", - "type_name": "map[string]*Plan", - "json_tag": "plansById", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 105, - "is_exported": true - }, - { - "name": "TellPlanRequest", - "fields": [ - { - "name": "Prompt", - "type_name": "string", - "json_tag": "prompt", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "BuildMode", - "type_name": "BuildMode", - "json_tag": "buildMode", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ConnectStream", - "type_name": "bool", - "json_tag": "connectStream", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoContinue", - "type_name": "bool", - "json_tag": "autoContinue", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsUserContinue", - "type_name": "bool", - "json_tag": "isUserContinue", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsUserDebug", - "type_name": "bool", - "json_tag": "isUserDebug", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsApplyDebug", - "type_name": "bool", - "json_tag": "isApplyDebug", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsChatOnly", - "type_name": "bool", - "json_tag": "isChatOnly", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoContext", - "type_name": "bool", - "json_tag": "autoContext", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SmartContext", - "type_name": "bool", - "json_tag": "smartContext", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ExecEnabled", - "type_name": "bool", - "json_tag": "execEnabled", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "OsDetails", - "type_name": "string", - "json_tag": "osDetails", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ApiKeys", - "type_name": "map[string]string", - "json_tag": "apiKeys", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true, - "comment": "deprecated" - }, - { - "name": "OpenAIOrgId", - "type_name": "string", - "json_tag": "openAIOrgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "deprecated" - }, - { - "name": "AuthVars", - "type_name": "map[string]string", - "json_tag": "authVars", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "ProjectPaths", - "type_name": "map[string]bool", - "json_tag": "projectPaths", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "IsImplementationOfChat", - "type_name": "bool", - "json_tag": "isImplementationOfChat", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "IsGitRepo", - "type_name": "bool", - "json_tag": "isGitRepo", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SessionId", - "type_name": "string", - "json_tag": "sessionId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 120, - "is_exported": true - }, - { - "name": "BuildPlanRequest", - "fields": [ - { - "name": "ConnectStream", - "type_name": "bool", - "json_tag": "connectStream", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ApiKeys", - "type_name": "map[string]string", - "json_tag": "apiKeys", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true, - "comment": "deprecated" - }, - { - "name": "OpenAIOrgId", - "type_name": "string", - "json_tag": "openAIOrgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "deprecated" - }, - { - "name": "AuthVars", - "type_name": "map[string]string", - "json_tag": "authVars", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "ProjectPaths", - "type_name": "map[string]bool", - "json_tag": "projectPaths", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "SessionId", - "type_name": "string", - "json_tag": "sessionId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 145, - "is_exported": true - }, - { - "name": "RespondMissingFileRequest", - "fields": [ - { - "name": "Choice", - "type_name": "RespondMissingFileChoice", - "json_tag": "choice", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "FilePath", - "type_name": "string", - "json_tag": "filePath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Body", - "type_name": "string", - "json_tag": "body", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 167, - "is_exported": true - }, - { - "name": "LoadContextParams", - "fields": [ - { - "name": "ContextType", - "type_name": "ContextType", - "json_tag": "contextType", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Url", - "type_name": "string", - "json_tag": "url", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "FilePath", - "type_name": "string", - "json_tag": "file_path", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Body", - "type_name": "string", - "json_tag": "body", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ForceSkipIgnore", - "type_name": "bool", - "json_tag": "forceSkipIgnore", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ImageDetail", - "type_name": "openai.ImageURLDetail", - "json_tag": "imageDetail", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "AutoLoaded", - "type_name": "bool", - "json_tag": "autoLoaded", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "InputShas", - "type_name": "map[string]string", - "json_tag": "inputShas", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "InputTokens", - "type_name": "map[string]int", - "json_tag": "inputTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "InputSizes", - "type_name": "map[string]int64", - "json_tag": "inputSizes", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "MapBodies", - "type_name": "FileMapBodies", - "json_tag": "mapBodies", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "For naming piped data" - }, - { - "name": "ApiKeys", - "type_name": "map[string]string", - "json_tag": "apiKeys", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true, - "comment": "deprecated" - }, - { - "name": "OpenAIBase", - "type_name": "string", - "json_tag": "openAIBase", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "deprecated" - }, - { - "name": "OpenAIOrgId", - "type_name": "string", - "json_tag": "openAIOrgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "deprecated" - }, - { - "name": "AuthVars", - "type_name": "map[string]string", - "json_tag": "authVars", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "SessionId", - "type_name": "string", - "json_tag": "sessionId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 187, - "is_exported": true - }, - { - "name": "LoadContextResponse", - "fields": [ - { - "name": "TokensAdded", - "type_name": "int", - "json_tag": "tokensAdded", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TotalTokens", - "type_name": "int", - "json_tag": "totalTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MaxTokensExceeded", - "type_name": "bool", - "json_tag": "maxTokensExceeded", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MaxTokens", - "type_name": "int", - "json_tag": "maxTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Msg", - "type_name": "string", - "json_tag": "msg", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 214, - "is_exported": true - }, - { - "name": "UpdateContextParams", - "fields": [ - { - "name": "Body", - "type_name": "string", - "json_tag": "body", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "InputShas", - "type_name": "map[string]string", - "json_tag": "inputShas", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "InputTokens", - "type_name": "map[string]int", - "json_tag": "inputTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "InputSizes", - "type_name": "map[string]int64", - "json_tag": "inputSizes", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "MapBodies", - "type_name": "FileMapBodies", - "json_tag": "mapBodies", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "RemovedMapPaths", - "type_name": "string", - "json_tag": "removedMapPaths", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 222, - "is_exported": true - }, - { - "name": "GetFileMapRequest", - "fields": [ - { - "name": "MapInputs", - "type_name": "FileMapInputs", - "json_tag": "mapInputs", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 231, - "is_exported": true - }, - { - "name": "GetFileMapResponse", - "fields": [ - { - "name": "MapBodies", - "type_name": "FileMapBodies", - "json_tag": "mapBodies", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 235, - "is_exported": true - }, - { - "name": "LoadCachedFileMapRequest", - "fields": [ - { - "name": "FilePaths", - "type_name": "string", - "json_tag": "filePaths", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 239, - "is_exported": true - }, - { - "name": "LoadCachedFileMapResponse", - "fields": [ - { - "name": "LoadRes", - "type_name": "LoadContextResponse", - "json_tag": "loadRes", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "CachedByPath", - "type_name": "map[string]bool", - "json_tag": "cachedByPath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 243, - "is_exported": true - }, - { - "name": "GetContextBodyRequest", - "fields": [ - { - "name": "ContextId", - "type_name": "string", - "json_tag": "contextId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 248, - "is_exported": true - }, - { - "name": "GetContextBodyResponse", - "fields": [ - { - "name": "Body", - "type_name": "string", - "json_tag": "body", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 252, - "is_exported": true - }, - { - "name": "DeleteContextRequest", - "fields": [ - { - "name": "Ids", - "type_name": "map[string]bool", - "json_tag": "ids", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 260, - "is_exported": true - }, - { - "name": "DeleteContextResponse", - "fields": [ - { - "name": "TokensRemoved", - "type_name": "int", - "json_tag": "tokensRemoved", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TotalTokens", - "type_name": "int", - "json_tag": "totalTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Msg", - "type_name": "string", - "json_tag": "msg", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 264, - "is_exported": true - }, - { - "name": "RejectFileRequest", - "fields": [ - { - "name": "FilePath", - "type_name": "string", - "json_tag": "filePath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 270, - "is_exported": true - }, - { - "name": "RejectFilesRequest", - "fields": [ - { - "name": "Paths", - "type_name": "string", - "json_tag": "paths", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 274, - "is_exported": true - }, - { - "name": "RewindPlanRequest", - "fields": [ - { - "name": "Sha", - "type_name": "string", - "json_tag": "sha", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 278, - "is_exported": true - }, - { - "name": "RewindPlanResponse", - "fields": [ - { - "name": "LatestSha", - "type_name": "string", - "json_tag": "latestSha", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "LatestCommit", - "type_name": "string", - "json_tag": "latestCommit", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 282, - "is_exported": true - }, - { - "name": "LogResponse", - "fields": [ - { - "name": "Shas", - "type_name": "string", - "json_tag": "shas", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "Body", - "type_name": "string", - "json_tag": "body", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 287, - "is_exported": true - }, - { - "name": "CreateBranchRequest", - "fields": [ - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 292, - "is_exported": true - }, - { - "name": "UpdateSettingsRequest", - "fields": [ - { - "name": "ModelPackName", - "type_name": "string", - "json_tag": "modelPackName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ModelPack", - "type_name": "ModelPack", - "json_tag": "modelPack", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 296, - "is_exported": true - }, - { - "name": "UpdateSettingsResponse", - "fields": [ - { - "name": "Msg", - "type_name": "string", - "json_tag": "msg", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 301, - "is_exported": true - }, - { - "name": "UpdatePlanConfigRequest", - "fields": [ - { - "name": "Config", - "type_name": "PlanConfig", - "json_tag": "config", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 305, - "is_exported": true - }, - { - "name": "UpdateDefaultPlanConfigRequest", - "fields": [ - { - "name": "Config", - "type_name": "PlanConfig", - "json_tag": "config", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 309, - "is_exported": true - }, - { - "name": "GetPlanConfigResponse", - "fields": [ - { - "name": "Config", - "type_name": "PlanConfig", - "json_tag": "config", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 313, - "is_exported": true - }, - { - "name": "GetDefaultPlanConfigResponse", - "fields": [ - { - "name": "Config", - "type_name": "PlanConfig", - "json_tag": "config", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 317, - "is_exported": true - }, - { - "name": "ListUsersResponse", - "fields": [ - { - "name": "Users", - "type_name": "*User", - "json_tag": "users", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "OrgUsersByUserId", - "type_name": "map[string]*OrgUser", - "json_tag": "orgUsersByUserId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 321, - "is_exported": true - }, - { - "name": "ApplyPlanRequest", - "fields": [ - { - "name": "ApiKeys", - "type_name": "map[string]string", - "json_tag": "apiKeys", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true, - "comment": "deprecated" - }, - { - "name": "OpenAIBase", - "type_name": "string", - "json_tag": "openAIBase", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "deprecated" - }, - { - "name": "OpenAIOrgId", - "type_name": "string", - "json_tag": "openAIOrgId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false, - "comment": "deprecated" - }, - { - "name": "AuthVars", - "type_name": "map[string]string", - "json_tag": "authVars", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "SessionId", - "type_name": "string", - "json_tag": "sessionId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 326, - "is_exported": true - }, - { - "name": "RenamePlanRequest", - "fields": [ - { - "name": "Name", - "type_name": "string", - "json_tag": "name", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 336, - "is_exported": true - }, - { - "name": "GetBuildStatusResponse", - "fields": [ - { - "name": "BuiltFiles", - "type_name": "map[string]bool", - "json_tag": "builtFiles", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "IsBuildingByPath", - "type_name": "map[string]bool", - "json_tag": "isBuildingByPath", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 340, - "is_exported": true - }, - { - "name": "CreditsLogRequest", - "fields": [ - { - "name": "TransactionType", - "type_name": "CreditsTransactionType", - "json_tag": "transactionType", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PlanId", - "type_name": "string", - "json_tag": "planId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "SessionId", - "type_name": "string", - "json_tag": "sessionId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "DayStart", - "type_name": "time.Time", - "json_tag": "dayStart", - "omitempty": false, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "Month", - "type_name": "bool", - "json_tag": "month", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 346, - "is_exported": true - }, - { - "name": "CreditsLogResponse", - "fields": [ - { - "name": "Transactions", - "type_name": "*CreditsTransaction", - "json_tag": "transactions", - "omitempty": false, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "NumPages", - "type_name": "int", - "json_tag": "numPages", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumPagesMax", - "type_name": "bool", - "json_tag": "numPagesMax", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MonthStart", - "type_name": "time.Time", - "json_tag": "monthStart", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "PlanNamesById", - "type_name": "map[string]string", - "json_tag": "planNamesById", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 354, - "is_exported": true - }, - { - "name": "CreditsSummaryResponse", - "fields": [ - { - "name": "Balance", - "type_name": "decimal.Decimal", - "json_tag": "balance", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "TotalSpend", - "type_name": "decimal.Decimal", - "json_tag": "totalSpend", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MonthStart", - "type_name": "time.Time", - "json_tag": "monthStart", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ByPlanId", - "type_name": "map[string]decimal.Decimal", - "json_tag": "byPlanId", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "PlanNamesById", - "type_name": "map[string]string", - "json_tag": "planNamesById", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "ByModelName", - "type_name": "map[string]decimal.Decimal", - "json_tag": "byModelName", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "ByPurpose", - "type_name": "map[string]decimal.Decimal", - "json_tag": "byPurpose", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": true - }, - { - "name": "CacheSavings", - "type_name": "decimal.Decimal", - "json_tag": "cacheSavings", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 362, - "is_exported": true - }, - { - "name": "GetBalanceResponse", - "fields": [ - { - "name": "Balance", - "type_name": "decimal.Decimal", - "json_tag": "balance", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 378, - "is_exported": true - } - ], - "enums": [ - { - "name": "BuildMode", - "type_name": "string", - "values": [ - "BuildModeAuto", - "BuildModeNone" - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 115 - }, - { - "name": "RespondMissingFileChoice", - "type_name": "string", - "values": [ - "RespondMissingFileChoiceLoad", - "RespondMissingFileChoiceSkip", - "RespondMissingFileChoiceOverwrite" - ], - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 161 - } - ], - "type_aliases": [ - { - "name": "BuildMode", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 113 - }, - { - "name": "RespondMissingFileChoice", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 159 - }, - { - "name": "FileMapInputs", - "underlying_type": "map[string]string", - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 173 - }, - { - "name": "LoadContextRequest", - "underlying_type": "[]*LoadContextParams", - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 212 - }, - { - "name": "UpdateContextRequest", - "underlying_type": "map[string]*UpdateContextParams", - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 256 - }, - { - "name": "UpdateContextResponse", - "underlying_type": "=", - "file_path": "/app/robot/../plandex/app/shared/req_res.go", - "line_number": 258 - } - ] - }, - "stream": { - "package_name": "shared", - "imports": [], - "structs": [ - { - "name": "BuildInfo", - "fields": [ - { - "name": "Path", - "type_name": "string", - "json_tag": "path", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "NumTokens", - "type_name": "int", - "json_tag": "numTokens", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Finished", - "type_name": "bool", - "json_tag": "finished", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "Removed", - "type_name": "bool", - "json_tag": "removed", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/stream.go", - "line_number": 5, - "is_exported": true - }, - { - "name": "StreamMessage", - "fields": [ - { - "name": "Type", - "type_name": "StreamMessageType", - "json_tag": "type", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ReplyChunk", - "type_name": "string", - "json_tag": "replyChunk", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "BuildInfo", - "type_name": "BuildInfo", - "json_tag": "buildInfo", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "Description", - "type_name": "ConvoMessageDescription", - "json_tag": "description", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "Error", - "type_name": "ApiError", - "json_tag": "error", - "omitempty": true, - "is_optional": true, - "is_array": false, - "is_map": false - }, - { - "name": "MissingFilePath", - "type_name": "string", - "json_tag": "missingFilePath", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "MissingFileAutoContext", - "type_name": "bool", - "json_tag": "missingFileAutoContext", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "ModelStreamId", - "type_name": "string", - "json_tag": "modelStreamId", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "LoadContextFiles", - "type_name": "string", - "json_tag": "loadContextFiles", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "InitPrompt", - "type_name": "string", - "json_tag": "initPrompt", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "InitReplies", - "type_name": "string", - "json_tag": "initReplies", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - }, - { - "name": "InitBuildOnly", - "type_name": "bool", - "json_tag": "initBuildOnly", - "omitempty": true, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "StreamMessages", - "type_name": "StreamMessage", - "json_tag": "streamMessages", - "omitempty": true, - "is_optional": false, - "is_array": true, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/stream.go", - "line_number": 31, - "is_exported": true - } - ], - "enums": [ - { - "name": "StreamMessageType", - "type_name": "string", - "values": [ - "StreamMessageStart", - "StreamMessageConnectActive", - "StreamMessageHeartbeat", - "StreamMessageReply", - "StreamMessageDescribing", - "StreamMessageRepliesFinished", - "StreamMessageBuildInfo", - "StreamMessagePromptMissingFile", - "StreamMessageLoadContext", - "StreamMessageAborted", - "StreamMessageFinished", - "StreamMessageError", - "StreamMessageMulti" - ], - "file_path": "/app/robot/../plandex/app/shared/stream.go", - "line_number": 14 - } - ], - "type_aliases": [ - { - "name": "StreamMessageType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/stream.go", - "line_number": 12 - } - ] - }, - "streamed_change": { - "package_name": "shared", - "imports": [ - "fmt", - "log", - "strconv", - "strings" - ], - "structs": [ - { - "name": "StreamedChangeSection", - "fields": [ - { - "name": "StartLine", - "type_name": "int", - "json_tag": "startLine", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "EndLine", - "type_name": "int", - "json_tag": "endLine", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "StartLineString", - "type_name": "string", - "json_tag": "startLineString", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "EndLineString", - "type_name": "string", - "json_tag": "endLineString", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/streamed_change.go", - "line_number": 10, - "is_exported": true - }, - { - "name": "StreamedChangeWithLineNums", - "fields": [ - { - "name": "Old", - "type_name": "StreamedChangeSection", - "json_tag": "old", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "StartLineIncluded", - "type_name": "bool", - "json_tag": "startLineIncluded", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "EndLineIncluded", - "type_name": "bool", - "json_tag": "endLineIncluded", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - }, - { - "name": "New", - "type_name": "string", - "json_tag": "new", - "omitempty": false, - "is_optional": false, - "is_array": false, - "is_map": false - } - ], - "file_path": "/app/robot/../plandex/app/shared/streamed_change.go", - "line_number": 17, - "is_exported": true - } - ], - "enums": [], - "type_aliases": [] - }, - "syntax": { - "package_name": "shared", - "imports": [ - "path/filepath", - "strings" - ], - "structs": [], - "enums": [ - { - "name": "Language", - "type_name": "string", - "values": [ - "LanguageBash", - "LanguageC", - "LanguageCpp", - "LanguageCsharp", - "LanguageCss", - "LanguageCue", - "LanguageDockerfile", - "LanguageElixir", - "LanguageElm", - "LanguageGo", - "LanguageGroovy", - "LanguageHcl", - "LanguageHtml", - "LanguageJava", - "LanguageJavascript", - "LanguageJson", - "LanguageKotlin", - "LanguageLua", - "LanguageOCaml", - "LanguagePhp", - "LanguageProtobuf", - "LanguagePython", - "LanguageRuby", - "LanguageRust", - "LanguageScala", - "LanguageSvelte", - "LanguageSwift", - "LanguageToml", - "LanguageTypescript", - "LanguageJsx", - "LanguageTsx", - "LanguageYaml", - "LanguageMarkdown" - ], - "file_path": "/app/robot/../plandex/app/shared/syntax.go", - "line_number": 10 - } - ], - "type_aliases": [ - { - "name": "Language", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/syntax.go", - "line_number": 8 - } - ] - }, - "utils": { - "package_name": "shared", - "imports": [ - "bytes", - "crypto/rand", - "fmt", - "regexp", - "strings", - "time", - "unicode/utf8" - ], - "structs": [], - "enums": [], - "type_aliases": [ - { - "name": "LineNumberedTextType", - "underlying_type": "string", - "file_path": "/app/robot/../plandex/app/shared/utils.go", - "line_number": 74 - } - ] - } -} \ No newline at end of file diff --git a/docs/reference/contracts/data_contracts.yaml b/docs/reference/contracts/data_contracts.yaml deleted file mode 100644 index d8f6c7b29..000000000 --- a/docs/reference/contracts/data_contracts.yaml +++ /dev/null @@ -1,5695 +0,0 @@ -ai_models_credentials: - package_name: shared - imports: [] - structs: - - name: ModelProviderOption - fields: - - name: Publishers - type_name: map[ModelPublisher]bool - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: Config - type_name: ModelProviderConfigSchema - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: Priority - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_credentials.go - line_number: 3 - is_exported: true - enums: [] - type_aliases: - - name: ModelProviderOptions - underlying_type: map[string]ModelProviderOption - file_path: /app/robot/../plandex/app/shared/ai_models_credentials.go - line_number: 9 -ai_models_custom: - package_name: shared - imports: - - crypto/sha256 - - encoding/hex - - encoding/json - - fmt - - strings - - time - - github.com/google/go-cmp/cmp - - github.com/google/go-cmp/cmp/cmpopts - structs: - - name: CustomModel - fields: - - name: Id - type_name: string - json_tag: id - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ModelId - type_name: ModelId - json_tag: modelId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Publisher - type_name: ModelPublisher - json_tag: publisher - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Providers - type_name: BaseModelUsesProvider - json_tag: providers - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: true - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_custom.go - line_number: 25 - is_exported: true - - name: CustomProvider - fields: - - name: Id - type_name: string - json_tag: id - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: BaseUrl - type_name: string - json_tag: baseUrl - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: for AWS Bedrock models - - name: HasAWSAuth - type_name: bool - json_tag: hasAWSAuth - omitempty: true - is_optional: false - is_array: false - is_map: false - comment: for local models that don't require auth (ollama, etc.) - - name: SkipAuth - type_name: bool - json_tag: skipAuth - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ApiKeyEnvVar - type_name: string - json_tag: apiKeyEnvVar - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ExtraAuthVars - type_name: ModelProviderExtraAuthVars - json_tag: extraAuthVars - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: true - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_custom.go - line_number: 39 - is_exported: true - - name: ModelsInput - fields: - - name: CustomModels - type_name: '*CustomModel' - json_tag: models - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: CustomProviders - type_name: '*CustomProvider' - json_tag: providers - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: CustomModelPacks - type_name: '*ModelPackSchema' - json_tag: modelPacks - omitempty: true - is_optional: false - is_array: true - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_custom.go - line_number: 57 - is_exported: true - - name: ClientModelPackSchema - fields: - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_custom.go - line_number: 191 - is_exported: true - - name: ClientModelsInput - fields: - - name: SchemaUrl - type_name: SchemaUrl - json_tag: $schema - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CustomModels - type_name: '*CustomModel' - json_tag: models - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: CustomProviders - type_name: '*CustomProvider' - json_tag: providers - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: CustomModelPacks - type_name: '*ClientModelPackSchema' - json_tag: modelPacks - omitempty: true - is_optional: false - is_array: true - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_custom.go - line_number: 214 - is_exported: true - enums: - - name: SchemaUrl - type_name: string - values: - - SchemaUrlInputConfig - - SchemaUrlPlanConfig - - SchemaUrlInlineModelPack - file_path: /app/robot/../plandex/app/shared/ai_models_custom.go - line_number: 17 - type_aliases: - - name: SchemaUrl - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_custom.go - line_number: 15 -ai_models_data_models: - package_name: shared - imports: - - crypto/sha256 - - database/sql/driver - - encoding/hex - - encoding/json - - fmt - - reflect - - strings - - time - structs: - - name: ModelCompatibility - fields: - - name: HasImageSupport - type_name: bool - json_tag: hasImageSupport - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 14 - is_exported: true - - name: BaseModelShared - fields: - - name: DefaultMaxConvoTokens - type_name: int - json_tag: defaultMaxConvoTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MaxTokens - type_name: int - json_tag: maxTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MaxOutputTokens - type_name: int - json_tag: maxOutputTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ReservedOutputTokens - type_name: int - json_tag: reservedOutputTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: PreferredOutputFormat - type_name: ModelOutputFormat - json_tag: preferredOutputFormat - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SystemPromptDisabled - type_name: bool - json_tag: systemPromptDisabled - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: RoleParamsDisabled - type_name: bool - json_tag: roleParamsDisabled - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: StopDisabled - type_name: bool - json_tag: stopDisabled - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: PredictedOutputEnabled - type_name: bool - json_tag: predictedOutputEnabled - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ReasoningEffortEnabled - type_name: bool - json_tag: reasoningEffortEnabled - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ReasoningEffort - type_name: ReasoningEffort - json_tag: reasoningEffort - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: IncludeReasoning - type_name: bool - json_tag: includeReasoning - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: HideReasoning - type_name: bool - json_tag: hideReasoning - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ReasoningBudget - type_name: int - json_tag: reasoningBudget - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: SupportsCacheControl - type_name: bool - json_tag: supportsCacheControl - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: SingleMessageNoSystemPrompt - type_name: bool - json_tag: singleMessageNoSystemPrompt - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: TokenEstimatePaddingPct - type_name: float64 - json_tag: tokenEstimatePaddingPct - omitempty: true - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 31 - is_exported: true - - name: BaseModelProviderConfig - fields: - - name: ModelName - type_name: ModelName - json_tag: modelName - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 52 - is_exported: true - - name: BaseModelConfig - fields: - - name: ModelTag - type_name: ModelTag - json_tag: modelTag - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ModelId - type_name: ModelId - json_tag: modelId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Publisher - type_name: ModelPublisher - json_tag: publisher - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: BaseModelShared - type_name: BaseModelProviderConfig - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 57 - is_exported: true - - name: BaseModelUsesProvider - fields: - - name: Provider - type_name: ModelProvider - json_tag: provider - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CustomProvider - type_name: string - json_tag: customProvider - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: ModelName - type_name: ModelName - json_tag: modelName - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 65 - is_exported: true - - name: BaseModelConfigSchema - fields: - - name: ModelTag - type_name: ModelTag - json_tag: modelTag - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ModelId - type_name: ModelId - json_tag: modelId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Publisher - type_name: ModelPublisher - json_tag: publisher - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: RequiresVariantOverrides - type_name: string - json_tag: requiresVariantOverrides - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: Variants - type_name: BaseModelConfigVariant - json_tag: variants - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: Providers - type_name: BaseModelUsesProvider - json_tag: providers - omitempty: false - is_optional: false - is_array: true - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 78 - is_exported: true - - name: BaseModelConfigVariant - fields: - - name: IsBaseVariant - type_name: bool - json_tag: isBaseVariant - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: VariantTag - type_name: VariantTag - json_tag: variantTag - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Overrides - type_name: BaseModelShared - json_tag: overrides - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Variants - type_name: BaseModelConfigVariant - json_tag: variants - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: RequiresVariantOverrides - type_name: string - json_tag: requiresVariantOverrides - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: IsDefaultVariant - type_name: bool - json_tag: isDefaultVariant - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 92 - is_exported: true - - name: AvailableModel - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DefaultMaxConvoTokens - type_name: int - json_tag: defaultMaxConvoTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 256 - is_exported: true - - name: PlannerModelConfig - fields: - - name: MaxConvoTokens - type_name: int - json_tag: maxConvoTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 274 - is_exported: true - - name: ModelRoleConfig - fields: - - name: Role - type_name: ModelRole - json_tag: role - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ModelId - type_name: ModelId - json_tag: modelId - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: "new in 2.2.0 refactor \u2014 uses provider lookup instead of BaseModelConfig\ - \ and MissingKeyFallback" - - name: BaseModelConfig - type_name: BaseModelConfig - json_tag: baseModelConfig - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: Temperature - type_name: float32 - json_tag: temperature - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TopP - type_name: float32 - json_tag: topP - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ReservedOutputTokens - type_name: int - json_tag: reservedOutputTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: LargeContextFallback - type_name: ModelRoleConfig - json_tag: largeContextFallback - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: LargeOutputFallback - type_name: ModelRoleConfig - json_tag: largeOutputFallback - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: ErrorFallback - type_name: ModelRoleConfig - json_tag: errorFallback - omitempty: false - is_optional: true - is_array: false - is_map: false - comment: "MissingKeyFallback *ModelRoleConfig // removed in 2.2.0 refactor \u2014" - - name: StrongModel - type_name: ModelRoleConfig - json_tag: strongModel - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: LocalProvider - type_name: ModelProvider - json_tag: localProvider - omitempty: true - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 286 - is_exported: true - - name: ModelRoleModelConfig - fields: - - name: Provider - type_name: ModelProvider - json_tag: provider - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CustomProvider - type_name: string - json_tag: customProvider - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: ModelTag - type_name: ModelTag - json_tag: modelTag - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 305 - is_exported: true - - name: ModelRoleConfigSchema - fields: - - name: ModelId - type_name: ModelId - json_tag: modelId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Temperature - type_name: float32 - json_tag: temperature - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: TopP - type_name: float32 - json_tag: topP - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: ReservedOutputTokens - type_name: int - json_tag: reservedOutputTokens - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: MaxConvoTokens - type_name: int - json_tag: maxConvoTokens - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: LargeContextFallback - type_name: ModelRoleConfigSchema - json_tag: largeContextFallback - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: LargeOutputFallback - type_name: ModelRoleConfigSchema - json_tag: largeOutputFallback - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: ErrorFallback - type_name: ModelRoleConfigSchema - json_tag: errorFallback - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: StrongModel - type_name: ModelRoleConfigSchema - json_tag: strongModel - omitempty: true - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 311 - is_exported: true - - name: PlannerRoleConfig - fields: - - name: ModelRoleConfig - type_name: PlannerModelConfig - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 677 - is_exported: true - - name: ClientModelPackSchemaRoles - fields: - - name: SchemaUrl - type_name: SchemaUrl - json_tag: $schema - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: LocalProvider - type_name: ModelProvider - json_tag: localProvider - omitempty: true - is_optional: false - is_array: false - is_map: false - comment: in the JSON, these can either be a role as a string or a ModelRoleConfigSchema - object for more complex config - - name: Planner - type_name: RoleJSON - json_tag: planner - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Architect - type_name: RoleJSON - json_tag: architect - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: Coder - type_name: RoleJSON - json_tag: coder - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: PlanSummary - type_name: RoleJSON - json_tag: summarizer - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Builder - type_name: RoleJSON - json_tag: builder - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: WholeFileBuilder - type_name: RoleJSON - json_tag: wholeFileBuilder - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: Namer - type_name: RoleJSON - json_tag: names - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CommitMsg - type_name: RoleJSON - json_tag: commitMessages - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ExecStatus - type_name: RoleJSON - json_tag: autoContinue - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 710 - is_exported: true - - name: ModelPackSchemaRoles - fields: - - name: LocalProvider - type_name: ModelProvider - json_tag: localProvider - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: Planner - type_name: ModelRoleConfigSchema - json_tag: planner - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Coder - type_name: ModelRoleConfigSchema - json_tag: coder - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: PlanSummary - type_name: ModelRoleConfigSchema - json_tag: planSummary - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Builder - type_name: ModelRoleConfigSchema - json_tag: builder - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: WholeFileBuilder - type_name: ModelRoleConfigSchema - json_tag: wholeFileBuilder - omitempty: true - is_optional: true - is_array: false - is_map: false - comment: "optional, defaults to builder model \u2014 access via GetWholeFileBuilder()" - - name: Namer - type_name: ModelRoleConfigSchema - json_tag: namer - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CommitMsg - type_name: ModelRoleConfigSchema - json_tag: commitMsg - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ExecStatus - type_name: ModelRoleConfigSchema - json_tag: execStatus - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Architect - type_name: ModelRoleConfigSchema - json_tag: contextLoader - omitempty: true - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 797 - is_exported: true - - name: ModelPackSchema - fields: - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 838 - is_exported: true - - name: ModelPack - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: LocalProvider - type_name: ModelProvider - json_tag: localProvider - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Planner - type_name: PlannerRoleConfig - json_tag: planner - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Coder - type_name: ModelRoleConfig - json_tag: coder - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: PlanSummary - type_name: ModelRoleConfig - json_tag: planSummary - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Builder - type_name: ModelRoleConfig - json_tag: builder - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: WholeFileBuilder - type_name: ModelRoleConfig - json_tag: wholeFileBuilder - omitempty: false - is_optional: true - is_array: false - is_map: false - comment: "optional, defaults to builder model \u2014 access via GetWholeFileBuilder()" - - name: Namer - type_name: ModelRoleConfig - json_tag: namer - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CommitMsg - type_name: ModelRoleConfig - json_tag: commitMsg - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ExecStatus - type_name: ModelRoleConfig - json_tag: execStatus - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Architect - type_name: ModelRoleConfig - json_tag: contextLoader - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 920 - is_exported: true - enums: - - name: ModelOutputFormat - type_name: string - values: - - ModelOutputFormatToolCallJson - - ModelOutputFormatXml - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 20 - - name: ReasoningEffort - type_name: string - values: - - ReasoningEffortLow - - ReasoningEffortMedium - - ReasoningEffortHigh - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 280 - type_aliases: - - name: ModelOutputFormat - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 18 - - name: ModelName - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 26 - - name: ModelId - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 27 - - name: ModelTag - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 28 - - name: VariantTag - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 29 - - name: ReasoningEffort - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 278 - - name: RoleJSON - underlying_type: any - file_path: /app/robot/../plandex/app/shared/ai_models_data_models.go - line_number: 708 -ai_models_errors: - package_name: shared - imports: - - log - - github.com/davecgh/go-spew/spew - - github.com/jinzhu/copier - structs: - - name: ModelError - fields: - - name: Kind - type_name: ModelErrKind - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Retriable - type_name: bool - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: RetryAfterSeconds - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_errors.go - line_number: 21 - is_exported: true - - name: FallbackResult - fields: - - name: ModelRoleConfig - type_name: ModelRoleConfig - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: IsFallback - type_name: bool - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: FallbackType - type_name: FallbackType - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: BaseModelConfig - type_name: BaseModelConfig - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_errors.go - line_number: 40 - is_exported: true - enums: - - name: ModelErrKind - type_name: string - values: - - ErrOverloaded - - ErrContextTooLong - - ErrRateLimited - - ErrSubscriptionQuotaExhausted - - ErrOther - - ErrCacheSupport - file_path: /app/robot/../plandex/app/shared/ai_models_errors.go - line_number: 12 - - name: FallbackType - type_name: string - values: - - FallbackTypeError - - FallbackTypeContext - - FallbackTypeProvider - file_path: /app/robot/../plandex/app/shared/ai_models_errors.go - line_number: 34 - type_aliases: - - name: ModelErrKind - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_errors.go - line_number: 10 - - name: FallbackType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_errors.go - line_number: 32 -ai_models_openrouter: - package_name: shared - imports: [] - structs: [] - enums: - - name: OpenRouterFamily - type_name: string - values: - - OpenRouterFamilyAnthropic - - OpenRouterFamilyGoogle - - OpenRouterFamilyOpenAI - - OpenRouterFamilyQwen - - OpenRouterFamilyDeepSeek - file_path: /app/robot/../plandex/app/shared/ai_models_openrouter.go - line_number: 5 - type_aliases: - - name: OpenRouterFamily - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_openrouter.go - line_number: 3 -ai_models_providers: - package_name: shared - imports: - - fmt - structs: - - name: ModelProviderExtraAuthVars - fields: - - name: Var - type_name: string - json_tag: var - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MaybeJSONFilePath - type_name: bool - json_tag: maybeJSONFilePath - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: Required - type_name: bool - json_tag: required - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: Default - type_name: string - json_tag: default - omitempty: true - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_providers.go - line_number: 79 - is_exported: true - - name: ModelProviderConfigSchema - fields: - - name: Provider - type_name: ModelProvider - json_tag: provider - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CustomProvider - type_name: string - json_tag: customProvider - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: BaseUrl - type_name: string - json_tag: baseUrl - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: for AWS Bedrock models - - name: HasAWSAuth - type_name: bool - json_tag: hasAWSAuth - omitempty: true - is_optional: false - is_array: false - is_map: false - comment: for Claude Max integration - - name: HasClaudeMaxAuth - type_name: bool - json_tag: hasClaudeMaxAuth - omitempty: true - is_optional: false - is_array: false - is_map: false - comment: for local models that don't require auth (ollama, etc.) - - name: SkipAuth - type_name: bool - json_tag: skipAuth - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: LocalOnly - type_name: bool - json_tag: localOnly - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ApiKeyEnvVar - type_name: string - json_tag: apiKeyEnvVar - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ExtraAuthVars - type_name: ModelProviderExtraAuthVars - json_tag: extraAuthVars - omitempty: true - is_optional: false - is_array: true - is_map: false - file_path: /app/robot/../plandex/app/shared/ai_models_providers.go - line_number: 86 - is_exported: true - enums: - - name: ModelPublisher - type_name: string - values: - - ModelPublisherOpenAI - - ModelPublisherAnthropic - - ModelPublisherGoogle - - ModelPublisherDeepSeek - - ModelPublisherPerplexity - - ModelPublisherQwen - - ModelPublisherMistral - file_path: /app/robot/../plandex/app/shared/ai_models_providers.go - line_number: 26 - - name: ModelProvider - type_name: string - values: - - ModelProviderOpenRouter - - ModelProviderOpenAI - - ModelProviderAnthropic - - ModelProviderAnthropicClaudeMax - - ModelProviderGoogleAIStudio - - ModelProviderGoogleVertex - - ModelProviderAzureOpenAI - - ModelProviderDeepSeek - - ModelProviderPerplexity - - ModelProviderAmazonBedrock - - ModelProviderOllama - - ModelProviderCustom - file_path: /app/robot/../plandex/app/shared/ai_models_providers.go - line_number: 38 - type_aliases: - - name: ModelPublisher - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_providers.go - line_number: 24 - - name: ModelProvider - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_providers.go - line_number: 36 -ai_models_roles: - package_name: shared - imports: [] - structs: [] - enums: - - name: ModelRole - type_name: string - values: - - ModelRolePlanner - - ModelRoleCoder - - ModelRoleArchitect - - ModelRolePlanSummary - - ModelRoleBuilder - - ModelRoleWholeFileBuilder - - ModelRoleName - - ModelRoleCommitMsg - - ModelRoleExecStatus - file_path: /app/robot/../plandex/app/shared/ai_models_roles.go - line_number: 5 - type_aliases: - - name: ModelRole - underlying_type: string - file_path: /app/robot/../plandex/app/shared/ai_models_roles.go - line_number: 3 -auth: - package_name: shared - imports: - - crypto/sha256 - - encoding/hex - - fmt - - strconv - - strings - structs: - - name: AuthHeader - fields: - - name: Token - type_name: string - json_tag: token - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgId - type_name: string - json_tag: orgId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Hash - type_name: string - json_tag: hash - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 11 - is_exported: true - - name: TrialPlansExceededError - fields: - - name: MaxPlans - type_name: int - json_tag: maxPlans - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 36 - is_exported: true - - name: TrialMessagesExceededError - fields: - - name: MaxReplies - type_name: int - json_tag: maxMessages - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 40 - is_exported: true - - name: BillingError - fields: - - name: HasBillingPermission - type_name: bool - json_tag: hasBillingPermission - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsTrial - type_name: bool - json_tag: isTrial - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 44 - is_exported: true - - name: ApiError - fields: - - name: Type - type_name: ApiErrorType - json_tag: type - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Status - type_name: int - json_tag: status - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Msg - type_name: string - json_tag: msg - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: only used for trial plans exceeded error - - name: TrialPlansExceededError - type_name: TrialPlansExceededError - json_tag: trialPlansExceededError - omitempty: true - is_optional: true - is_array: false - is_map: false - comment: only used for trial messages exceeded error - - name: TrialMessagesExceededError - type_name: TrialMessagesExceededError - json_tag: trialMessagesExceededError - omitempty: true - is_optional: true - is_array: false - is_map: false - comment: only used for billing errors - - name: BillingError - type_name: BillingError - json_tag: billingError - omitempty: true - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 49 - is_exported: true - - name: ClientAccount - fields: - - name: IsCloud - type_name: bool - json_tag: isCloud - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Host - type_name: string - json_tag: host - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserName - type_name: string - json_tag: userName - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserId - type_name: string - json_tag: userId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Token - type_name: string - json_tag: token - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsLocalMode - type_name: bool - json_tag: isLocalMode - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsTrial - type_name: bool - json_tag: isTrial - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: legacy field - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 68 - is_exported: true - - name: ClientAuth - fields: - - name: OrgId - type_name: string - json_tag: orgId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgName - type_name: string - json_tag: orgName - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgIsTrial - type_name: bool - json_tag: orgIsTrial - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IntegratedModelsMode - type_name: bool - json_tag: integratedModelsMode - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 80 - is_exported: true - enums: - - name: ApiErrorType - type_name: string - values: - - ApiErrorTypeInvalidToken - - ApiErrorTypeAuthOutdated - - ApiErrorTypeTrialPlansExceeded - - ApiErrorTypeTrialMessagesExceeded - - ApiErrorTypeTrialActionNotAllowed - - ApiErrorTypeContinueNoMessages - - ApiErrorTypeCloudInsufficientCredits - - ApiErrorTypeCloudMonthlyMaxReached - - ApiErrorTypeCloudSubscriptionPaused - - ApiErrorTypeCloudSubscriptionOverdue - - ApiErrorTypeOther - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 19 - type_aliases: - - name: ApiErrorType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/auth.go - line_number: 17 -context: - package_name: shared - imports: - - fmt - - math - - strconv - - strings - - github.com/olekukonko/tablewriter - structs: - - name: ContextUpdateResult - fields: - - name: UpdatedContexts - type_name: '*Context' - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: TokenDiffsById - type_name: map[string]int - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: TokensDiff - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TotalTokens - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumFiles - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumUrls - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumImages - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumTrees - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumMaps - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MaxTokens - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/context.go - line_number: 24 - is_exported: true - - name: SummaryForUpdateContextParams - fields: - - name: NumFiles - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumTrees - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumUrls - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumMaps - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TokensDiff - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TotalTokens - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/context.go - line_number: 237 - is_exported: true - enums: - - name: MaxContextCount - type_name: string - values: - - 25MB - file_path: /app/robot/../plandex/app/shared/context.go - line_number: 12 - type_aliases: [] -data_models: - package_name: shared - imports: - - time - - github.com/sashabaranov/go-openai - - github.com/shopspring/decimal - structs: - - name: Org - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsTrial - type_name: bool - json_tag: isTrial - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoAddDomainUsers - type_name: bool - json_tag: autoAddDomainUsers - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: optional cloud attributes - - name: IntegratedModelsMode - type_name: bool - json_tag: integratedModelsMode - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: CloudBillingFields - type_name: CloudBillingFields - json_tag: cloudBillingFields - omitempty: true - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 10 - is_exported: true - - name: User - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsTrial - type_name: bool - json_tag: isTrial - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumNonDraftPlans - type_name: int - json_tag: numNonDraftPlans - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DefaultPlanConfig - type_name: PlanConfig - json_tag: defaultPlanConfig - omitempty: true - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 21 - is_exported: true - - name: OrgUser - fields: - - name: OrgId - type_name: string - json_tag: orgId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserId - type_name: string - json_tag: userId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgRoleId - type_name: string - json_tag: orgRoleId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Config - type_name: OrgUserConfig - json_tag: config - omitempty: true - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 31 - is_exported: true - - name: Invite - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgId - type_name: string - json_tag: orgId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgRoleId - type_name: string - json_tag: orgRoleId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: InviterId - type_name: string - json_tag: inviterId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: InviteeId - type_name: string - json_tag: inviteeId - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: AcceptedAt - type_name: time.Time - json_tag: acceptedAt - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 39 - is_exported: true - - name: Project - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 51 - is_exported: true - - name: Plan - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OwnerId - type_name: string - json_tag: ownerId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ProjectId - type_name: string - json_tag: projectId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SharedWithOrgAt - type_name: time.Time - json_tag: sharedWithOrgAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: TotalReplies - type_name: int - json_tag: totalReplies - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ActiveBranches - type_name: int - json_tag: activeBranches - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: PlanConfig - type_name: PlanConfig - json_tag: planConfig - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: ArchivedAt - type_name: time.Time - json_tag: archivedAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 56 - is_exported: true - - name: Branch - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: PlanId - type_name: string - json_tag: planId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OwnerId - type_name: string - json_tag: ownerId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ParentBranchId - type_name: string - json_tag: parentBranchId - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Status - type_name: PlanStatus - json_tag: status - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ContextTokens - type_name: int - json_tag: contextTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ConvoTokens - type_name: int - json_tag: convoTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SharedWithOrgAt - type_name: time.Time - json_tag: sharedWithOrgAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: ArchivedAt - type_name: time.Time - json_tag: archivedAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 70 - is_exported: true - - name: Context - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OwnerId - type_name: string - json_tag: ownerId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ContextType - type_name: ContextType - json_tag: contextType - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Url - type_name: string - json_tag: url - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: FilePath - type_name: string - json_tag: file_path - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Sha - type_name: string - json_tag: sha - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumTokens - type_name: int - json_tag: numTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Body - type_name: string - json_tag: body - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: BodySize - type_name: int64 - json_tag: bodySize - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ForceSkipIgnore - type_name: bool - json_tag: forceSkipIgnore - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ImageDetail - type_name: openai.ImageURLDetail - json_tag: imageDetail - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: MapParts - type_name: FileMapBodies - json_tag: mapParts - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: MapShas - type_name: map[string]string - json_tag: mapShas - omitempty: true - is_optional: false - is_array: false - is_map: true - - name: MapTokens - type_name: map[string]int - json_tag: mapTokens - omitempty: true - is_optional: false - is_array: false - is_map: true - - name: MapSizes - type_name: map[string]int64 - json_tag: mapSizes - omitempty: true - is_optional: false - is_array: false - is_map: true - - name: AutoLoaded - type_name: bool - json_tag: autoLoaded - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 99 - is_exported: true - - name: CurrentStage - fields: - - name: TellStage - type_name: TellStage - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: PlanningPhase - type_name: PlanningPhase - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 135 - is_exported: true - - name: ConvoMessageFlags - fields: - - name: DidMakePlan - type_name: bool - json_tag: didMakePlan - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DidRemoveTasks - type_name: bool - json_tag: didRemoveTasks - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DidMakeDebuggingPlan - type_name: bool - json_tag: didMakeDebuggingPlan - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DidLoadContext - type_name: bool - json_tag: didLoadContext - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CurrentStage - type_name: CurrentStage - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsChat - type_name: bool - json_tag: isChat - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DidWriteCode - type_name: bool - json_tag: didWriteCode - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DidCompleteTask - type_name: bool - json_tag: didCompleteTask - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DidCompletePlan - type_name: bool - json_tag: didCompletePlan - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: HasUnfinishedSubtasks - type_name: bool - json_tag: hasUnfinishedSubtasks - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsApplyDebug - type_name: bool - json_tag: isApplyDebug - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsUserDebug - type_name: bool - json_tag: isUserDebug - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: HasError - type_name: bool - json_tag: hasError - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 140 - is_exported: true - - name: Subtask - fields: - - name: Title - type_name: string - json_tag: title - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UsesFiles - type_name: string - json_tag: usesFiles - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: IsFinished - type_name: bool - json_tag: isFinished - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 156 - is_exported: true - - name: ConvoMessage - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserId - type_name: string - json_tag: userId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Role - type_name: string - json_tag: role - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Tokens - type_name: int - json_tag: tokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Num - type_name: int - json_tag: num - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Message - type_name: string - json_tag: message - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Stopped - type_name: bool - json_tag: stopped - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Flags - type_name: ConvoMessageFlags - json_tag: flags - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Subtask - type_name: Subtask - json_tag: subtask - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: AddedSubtasks - type_name: '*Subtask' - json_tag: addedSubtasks - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: RemovedSubtasks - type_name: string - json_tag: removedSubtasks - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: ActiveContextIds - type_name: string - json_tag: activeContextIds - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 163 - is_exported: true - - name: ConvoSummary - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: LatestConvoMessageCreatedAt - type_name: time.Time - json_tag: latestConvoMessageCreatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: LatestConvoMessageId - type_name: string - json_tag: lastestConvoMessageId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Summary - type_name: string - json_tag: summary - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Tokens - type_name: int - json_tag: tokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumMessages - type_name: int - json_tag: numMessages - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 179 - is_exported: true - - name: Operation - fields: - - name: Type - type_name: OperationType - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Path - type_name: string - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Destination - type_name: string - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Content - type_name: string - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ReplyBefore - type_name: string - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumTokens - type_name: int - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 198 - is_exported: true - - name: ConvoMessageDescription - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ConvoMessageId - type_name: string - json_tag: convoMessageId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SummarizedToMessageId - type_name: string - json_tag: summarizedToMessageId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: WroteFiles - type_name: bool - json_tag: wroteFiles - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CommitMsg - type_name: string - json_tag: commitMsg - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: Files []string - - name: Operations - type_name: '*Operation' - json_tag: operations - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: DidBuild - type_name: bool - json_tag: didBuild - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: BuildPathsInvalidated - type_name: map[string]bool - json_tag: buildPathsInvalidated - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: Error - type_name: string - json_tag: error - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AppliedAt - type_name: time.Time - json_tag: appliedAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 216 - is_exported: true - - name: PlanBuild - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ConvoMessageId - type_name: string - json_tag: convoMessageId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: FilePath - type_name: string - json_tag: filePath - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Error - type_name: string - json_tag: error - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 232 - is_exported: true - - name: Replacement - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Old - type_name: string - json_tag: old - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Summary - type_name: string - json_tag: summary - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: EntireFile - type_name: bool - json_tag: entireFile - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: New - type_name: string - json_tag: new - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Failed - type_name: bool - json_tag: failed - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: RejectedAt - type_name: time.Time - json_tag: rejectedAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: StreamedChange - type_name: StreamedChangeWithLineNums - json_tag: streamedChange - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 241 - is_exported: true - - name: PlanFileResult - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TypeVersion - type_name: int - json_tag: typeVersion - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ReplaceWithLineNums - type_name: bool - json_tag: replaceWithLineNums - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ConvoMessageId - type_name: string - json_tag: convoMessageId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: PlanBuildId - type_name: string - json_tag: planBuildId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Path - type_name: string - json_tag: path - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Content - type_name: string - json_tag: content - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AnyFailed - type_name: bool - json_tag: anyFailed - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AppliedAt - type_name: time.Time - json_tag: appliedAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: RejectedAt - type_name: time.Time - json_tag: rejectedAt - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: Replacements - type_name: '*Replacement' - json_tag: replacements - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: RemovedFile - type_name: bool - json_tag: removedFile - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 252 - is_exported: true - - name: CurrentPlanFiles - fields: - - name: Files - type_name: map[string]string - json_tag: files - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: Removed - type_name: map[string]bool - json_tag: removedByPath - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: UpdatedAtByPath - type_name: map[string]time.Time - json_tag: updatedAtByPath - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 271 - is_exported: true - - name: PlanResult - fields: - - name: SortedPaths - type_name: string - json_tag: sortedPaths - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: FileResultsByPath - type_name: PlanFileResultsByPath - json_tag: fileResultsByPath - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Results - type_name: '*PlanFileResult' - json_tag: results - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: ReplacementsByPath - type_name: map[string][]*Replacement - json_tag: replacementsByPath - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 278 - is_exported: true - - name: PlanApply - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserId - type_name: string - json_tag: userId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ConvoMessageIds - type_name: string - json_tag: convoMessageIds - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: ConvoMessageDescriptionIds - type_name: string - json_tag: convoMessageDescriptionIds - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: PlanFileResultIds - type_name: string - json_tag: planFileResultIds - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: CommitMsg - type_name: string - json_tag: commitMsg - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 285 - is_exported: true - - name: CurrentPlanState - fields: - - name: PlanResult - type_name: PlanResult - json_tag: planResult - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: CurrentPlanFiles - type_name: CurrentPlanFiles - json_tag: currentPlanFiles - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: ConvoMessageDescriptions - type_name: '*ConvoMessageDescription' - json_tag: convoMessageDescriptions - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: PlanApplies - type_name: '*PlanApply' - json_tag: planApplies - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: ContextsByPath - type_name: map[string]*Context - json_tag: contextsByPath - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 295 - is_exported: true - - name: OrgRole - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsDefault - type_name: bool - json_tag: isDefault - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Label - type_name: string - json_tag: label - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Description - type_name: string - json_tag: description - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 303 - is_exported: true - - name: CloudBillingFields - fields: - - name: CreditsBalance - type_name: decimal.Decimal - json_tag: creditsBalance - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MonthlyGrant - type_name: decimal.Decimal - json_tag: monthlyGrant - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoRebuyEnabled - type_name: bool - json_tag: autoRebuyEnabled - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoRebuyMinThreshold - type_name: decimal.Decimal - json_tag: autoRebuyMinThreshold - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoRebuyToBalance - type_name: decimal.Decimal - json_tag: autoRebuyToBalance - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NotifyThreshold - type_name: decimal.Decimal - json_tag: notifyThreshold - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MaxThresholdPerMonth - type_name: decimal.Decimal - json_tag: maxThresholdPerMonth - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: BillingCycleStartedAt - type_name: time.Time - json_tag: billingCycleStartedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ChangedBillingMode - type_name: bool - json_tag: changedBillingMode - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TrialPaid - type_name: bool - json_tag: trialPaid - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: StripeSubscriptionId - type_name: string - json_tag: stripeSubscriptionId - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: SubscriptionStatus - type_name: string - json_tag: subscriptionStatus - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: SubscriptionPausedAt - type_name: time.Time - json_tag: subscriptionPausedAt - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: StripePaymentMethod - type_name: string - json_tag: stripePaymentMethod - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: SubscriptionActionRequired - type_name: bool - json_tag: subscriptionActionRequired - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: for 3ds/sca approvals - - name: SubscriptionActionRequiredInvoiceUrl - type_name: string - json_tag: subscriptionActionRequiredInvoiceUrl - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 310 - is_exported: true - - name: CreditsTransaction - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgId - type_name: string - json_tag: orgId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgName - type_name: string - json_tag: orgName - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserId - type_name: string - json_tag: userId - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: UserEmail - type_name: string - json_tag: userEmail - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: UserName - type_name: string - json_tag: userName - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: TransactionType - type_name: CreditsTransactionType - json_tag: transactionType - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Amount - type_name: decimal.Decimal - json_tag: amount - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: StartBalance - type_name: decimal.Decimal - json_tag: startBalance - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: EndBalance - type_name: decimal.Decimal - json_tag: endBalance - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CreditType - type_name: CreditType - json_tag: creditType - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: CreditIsAutoRebuy - type_name: bool - json_tag: creditIsAutoRebuy - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CreditAutoRebuyMinThreshold - type_name: decimal.Decimal - json_tag: creditAutoRebuyMinThreshold - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: CreditAutoRebuyToBalance - type_name: decimal.Decimal - json_tag: creditAutoRebuyToBalance - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitInputTokens - type_name: int - json_tag: debitInputTokens - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitOutputTokens - type_name: int - json_tag: debitOutputTokens - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitModelInputPricePerToken - type_name: decimal.Decimal - json_tag: debitModelInputPricePerToken - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitModelOutputPricePerToken - type_name: decimal.Decimal - json_tag: debitModelOutputPricePerToken - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitBaseAmount - type_name: decimal.Decimal - json_tag: debitBaseAmount - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitSurcharge - type_name: decimal.Decimal - json_tag: debitSurcharge - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitModelProvider - type_name: ModelProvider - json_tag: debitModelProvider - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitModelName - type_name: string - json_tag: debitModelName - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitModelPackName - type_name: string - json_tag: debitModelPackName - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitModelRole - type_name: ModelRole - json_tag: debitModelRole - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitPurpose - type_name: string - json_tag: debitPurpose - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitPlanId - type_name: string - json_tag: debitPlanId - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitPlanName - type_name: string - json_tag: debitPlanName - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitId - type_name: string - json_tag: debitId - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitCacheDiscount - type_name: decimal.Decimal - json_tag: debitCacheDiscount - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: DebitSessionId - type_name: string - json_tag: debitSessionId - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: CreatedAt - type_name: time.Time - json_tag: createdAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 348 - is_exported: true - enums: - - name: ContextType - type_name: string - values: - - ContextFileType - - ContextURLType - - ContextNoteType - - ContextDirectoryTreeType - - ContextPipedDataType - - ContextImageType - - ContextMapType - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 87 - - name: TellStage - type_name: string - values: - - TellStagePlanning - - TellStageImplementation - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 123 - - name: PlanningPhase - type_name: string - values: - - PlanningPhaseContext - - PlanningPhaseTasks - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 130 - - name: OperationType - type_name: string - values: - - OperationTypeFile - - OperationTypeMove - - OperationTypeRemove - - OperationTypeReset - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 191 - - name: CreditsTransactionType - type_name: string - values: - - CreditsTransactionTypeCredit - - CreditsTransactionTypeDebit - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 333 - - name: CreditType - type_name: string - values: - - CreditTypeTrial - - CreditTypeGrant - - CreditTypeAdminGrant - - CreditTypePurchase - - CreditTypeSwitch - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 340 - type_aliases: - - name: ContextType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 85 - - name: FileMapBodies - underlying_type: map[string]string - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 97 - - name: TellStage - underlying_type: string - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 121 - - name: PlanningPhase - underlying_type: string - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 128 - - name: OperationType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 189 - - name: PlanFileResultsByPath - underlying_type: map[string][]*PlanFileResult - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 277 - - name: CreditsTransactionType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 331 - - name: CreditType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/data_models.go - line_number: 338 -org_user_config: - package_name: shared - imports: - - database/sql/driver - - encoding/json - - fmt - - time - structs: - - name: OrgUserConfig - fields: - - name: PromptedClaudeMax - type_name: bool - json_tag: promptedClaudeMax - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UseClaudeSubscription - type_name: bool - json_tag: useClaudeSubscription - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ClaudeSubscriptionCooldownStartedAt - type_name: time.Time - json_tag: claudeSubscriptionCooldownStartedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/org_user_config.go - line_number: 14 - is_exported: true - enums: [] - type_aliases: [] -plan_config: - package_name: shared - imports: - - database/sql/driver - - encoding/json - - fmt - - strings - structs: - - name: PlanConfig - fields: - - name: AutoMode - type_name: AutoModeType - json_tag: autoMode - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: QuietMode bool - - name: Editor - type_name: string - json_tag: editor - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: EditorCommand - type_name: string - json_tag: editorCommand - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: EditorArgs - type_name: string - json_tag: editorArgs - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: EditorOpenManually - type_name: bool - json_tag: editorOpenManually - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoContinue - type_name: bool - json_tag: autoContinue - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoBuild - type_name: bool - json_tag: autoBuild - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoUpdateContext - type_name: bool - json_tag: autoUpdateContext - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoLoadContext - type_name: bool - json_tag: autoContext - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SmartContext - type_name: bool - json_tag: smartContext - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: AutoApproveContext bool - - name: AutoApply - type_name: bool - json_tag: autoApply - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoCommit - type_name: bool - json_tag: autoCommit - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SkipCommit - type_name: bool - json_tag: skipCommit - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: CanExec - type_name: bool - json_tag: canExec - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoExec - type_name: bool - json_tag: autoExec - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoDebug - type_name: bool - json_tag: autoDebug - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoDebugTries - type_name: int - json_tag: autoDebugTries - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoRevertOnRewind - type_name: bool - json_tag: autoRevertOnRewind - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SkipChangesMenu - type_name: bool - json_tag: skipChangesMenu - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: ReplMode bool - file_path: /app/robot/../plandex/app/shared/plan_config.go - line_number: 53 - is_exported: true - - name: ConfigSetting - fields: - - name: Name - type_name: string - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Desc - type_name: string - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Choices - type_name: string - omitempty: false - is_optional: true - is_array: true - is_map: false - - name: HasCustomChoice - type_name: bool - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SortKey - type_name: string - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/plan_config.go - line_number: 205 - is_exported: true - enums: - - name: string - type_name: string - values: - - EditorTypeVim - - EditorTypeNano - file_path: /app/robot/../plandex/app/shared/plan_config.go - line_number: 12 - - name: AutoModeType - type_name: string - values: - - AutoModeFull - - AutoModeSemi - - AutoModePlus - - AutoModeBasic - - AutoModeNone - - AutoModeCustom - file_path: /app/robot/../plandex/app/shared/plan_config.go - line_number: 21 - type_aliases: - - name: AutoModeType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/plan_config.go - line_number: 19 -plan_model_settings: - package_name: shared - imports: - - database/sql/driver - - encoding/json - - fmt - - time - structs: - - name: PlanSettings - fields: - - name: ModelPackName - type_name: string - json_tag: modelPackName - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ModelPack - type_name: ModelPack - json_tag: modelPack - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: CustomModelPacks - type_name: '*ModelPack' - json_tag: customModelPacks - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: CustomModels - type_name: '*CustomModel' - json_tag: customModels - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: CustomModelsById - type_name: map[ModelId]*CustomModel - json_tag: customModelsById - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: CustomProviders - type_name: '*CustomProvider' - json_tag: customProviders - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: UsesCustomProviderByModelId - type_name: map[ModelId][]BaseModelUsesProvider - json_tag: usesCustomProviderByModelId - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: IsCloud - type_name: bool - json_tag: isCloud - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Configured - type_name: bool - json_tag: configured - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UpdatedAt - type_name: time.Time - json_tag: updatedAt - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/plan_model_settings.go - line_number: 10 - is_exported: true - enums: [] - type_aliases: [] -plan_status: - package_name: shared - imports: [] - structs: [] - enums: - - name: PlanStatus - type_name: string - values: - - PlanStatusDraft - - PlanStatusReplying - - PlanStatusDescribing - - PlanStatusBuilding - - PlanStatusMissingFile - - PlanStatusFinished - - PlanStatusStopped - - PlanStatusError - file_path: /app/robot/../plandex/app/shared/plan_status.go - line_number: 5 - type_aliases: - - name: PlanStatus - underlying_type: string - file_path: /app/robot/../plandex/app/shared/plan_status.go - line_number: 3 -rbac: - package_name: shared - imports: - - strings - structs: [] - enums: - - name: Permission - type_name: string - values: - - PermissionDeleteOrg - - PermissionManageEmailDomainAuth - - PermissionManageBilling - - PermissionInviteUser - - PermissionRemoveUser - - PermissionSetUserRole - - PermissionListOrgRoles - - PermissionCreateProject - - PermissionRenameAnyProject - - PermissionDeleteAnyProject - - PermissionCreatePlan - - PermissionManageAnyPlanShares - - PermissionRenameAnyPlan - - PermissionDeleteAnyPlan - - PermissionUpdateAnyPlan - - PermissionArchiveAnyPlan - file_path: /app/robot/../plandex/app/shared/rbac.go - line_number: 9 - type_aliases: - - name: Permission - underlying_type: string - file_path: /app/robot/../plandex/app/shared/rbac.go - line_number: 7 - - name: Permissions - underlying_type: map[string]bool - file_path: /app/robot/../plandex/app/shared/rbac.go - line_number: 28 -req_res: - package_name: shared - imports: - - time - - github.com/sashabaranov/go-openai - - github.com/shopspring/decimal - structs: - - name: CreateEmailVerificationRequest - fields: - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserId - type_name: string - json_tag: userId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: RequireUser - type_name: bool - json_tag: requireUser - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: RequireNoUser - type_name: bool - json_tag: requireNoUser - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 10 - is_exported: true - - name: CreateEmailVerificationResponse - fields: - - name: HasAccount - type_name: bool - json_tag: hasAccount - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsLocalMode - type_name: bool - json_tag: isLocalMode - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 17 - is_exported: true - - name: VerifyEmailPinRequest - fields: - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Pin - type_name: string - json_tag: pin - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 22 - is_exported: true - - name: SignInRequest - fields: - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Pin - type_name: string - json_tag: pin - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsSignInCode - type_name: bool - json_tag: isSignInCode - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 27 - is_exported: true - - name: UiSignInToken - fields: - - name: Pin - type_name: string - json_tag: pin - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: RedirectTo - type_name: string - json_tag: redirectTo - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 33 - is_exported: true - - name: CreateAccountRequest - fields: - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Pin - type_name: string - json_tag: pin - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserName - type_name: string - json_tag: userName - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 38 - is_exported: true - - name: SessionResponse - fields: - - name: UserId - type_name: string - json_tag: userId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Token - type_name: string - json_tag: token - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserName - type_name: string - json_tag: userName - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Orgs - type_name: '*Org' - json_tag: orgs - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: IsLocalMode - type_name: bool - json_tag: isLocalMode - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 44 - is_exported: true - - name: CreateOrgRequest - fields: - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoAddDomainUsers - type_name: bool - json_tag: autoAddDomainUsers - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 53 - is_exported: true - - name: ConvertTrialRequest - fields: - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Pin - type_name: string - json_tag: pin - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: UserName - type_name: string - json_tag: userName - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgName - type_name: string - json_tag: orgName - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgAutoAddDomainUsers - type_name: bool - json_tag: orgAutoAddDomainUsers - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 58 - is_exported: true - - name: CreateOrgResponse - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 66 - is_exported: true - - name: InviteRequest - fields: - - name: Email - type_name: string - json_tag: email - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OrgRoleId - type_name: string - json_tag: orgRoleId - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 70 - is_exported: true - - name: CreateProjectRequest - fields: - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 76 - is_exported: true - - name: CreateProjectResponse - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 80 - is_exported: true - - name: SetProjectPlanRequest - fields: - - name: PlanId - type_name: string - json_tag: planId - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 84 - is_exported: true - - name: RenameProjectRequest - fields: - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 88 - is_exported: true - - name: CreatePlanRequest - fields: - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 92 - is_exported: true - - name: CreatePlanResponse - fields: - - name: Id - type_name: string - json_tag: id - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 96 - is_exported: true - - name: GetCurrentBranchByPlanIdRequest - fields: - - name: CurrentBranchByPlanId - type_name: map[string]string - json_tag: currentBranchByPlanId - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 101 - is_exported: true - - name: ListPlansRunningResponse - fields: - - name: Branches - type_name: '*Branch' - json_tag: branches - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: StreamStartedAtByBranchId - type_name: map[string]time.Time - json_tag: streamStartedAtByBranchId - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: StreamFinishedAtByBranchId - type_name: map[string]time.Time - json_tag: streamFinishedAtByBranchId - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: StreamIdByBranchId - type_name: map[string]string - json_tag: streamIdByBranchId - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: PlansById - type_name: map[string]*Plan - json_tag: plansById - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 105 - is_exported: true - - name: TellPlanRequest - fields: - - name: Prompt - type_name: string - json_tag: prompt - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: BuildMode - type_name: BuildMode - json_tag: buildMode - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ConnectStream - type_name: bool - json_tag: connectStream - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoContinue - type_name: bool - json_tag: autoContinue - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsUserContinue - type_name: bool - json_tag: isUserContinue - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsUserDebug - type_name: bool - json_tag: isUserDebug - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsApplyDebug - type_name: bool - json_tag: isApplyDebug - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsChatOnly - type_name: bool - json_tag: isChatOnly - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoContext - type_name: bool - json_tag: autoContext - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SmartContext - type_name: bool - json_tag: smartContext - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ExecEnabled - type_name: bool - json_tag: execEnabled - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: OsDetails - type_name: string - json_tag: osDetails - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ApiKeys - type_name: map[string]string - json_tag: apiKeys - omitempty: false - is_optional: false - is_array: false - is_map: true - comment: deprecated - - name: OpenAIOrgId - type_name: string - json_tag: openAIOrgId - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: deprecated - - name: AuthVars - type_name: map[string]string - json_tag: authVars - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: ProjectPaths - type_name: map[string]bool - json_tag: projectPaths - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: IsImplementationOfChat - type_name: bool - json_tag: isImplementationOfChat - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: IsGitRepo - type_name: bool - json_tag: isGitRepo - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SessionId - type_name: string - json_tag: sessionId - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 120 - is_exported: true - - name: BuildPlanRequest - fields: - - name: ConnectStream - type_name: bool - json_tag: connectStream - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ApiKeys - type_name: map[string]string - json_tag: apiKeys - omitempty: false - is_optional: false - is_array: false - is_map: true - comment: deprecated - - name: OpenAIOrgId - type_name: string - json_tag: openAIOrgId - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: deprecated - - name: AuthVars - type_name: map[string]string - json_tag: authVars - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: ProjectPaths - type_name: map[string]bool - json_tag: projectPaths - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: SessionId - type_name: string - json_tag: sessionId - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 145 - is_exported: true - - name: RespondMissingFileRequest - fields: - - name: Choice - type_name: RespondMissingFileChoice - json_tag: choice - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: FilePath - type_name: string - json_tag: filePath - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Body - type_name: string - json_tag: body - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 167 - is_exported: true - - name: LoadContextParams - fields: - - name: ContextType - type_name: ContextType - json_tag: contextType - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Url - type_name: string - json_tag: url - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: FilePath - type_name: string - json_tag: file_path - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Body - type_name: string - json_tag: body - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ForceSkipIgnore - type_name: bool - json_tag: forceSkipIgnore - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ImageDetail - type_name: openai.ImageURLDetail - json_tag: imageDetail - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: AutoLoaded - type_name: bool - json_tag: autoLoaded - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: InputShas - type_name: map[string]string - json_tag: inputShas - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: InputTokens - type_name: map[string]int - json_tag: inputTokens - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: InputSizes - type_name: map[string]int64 - json_tag: inputSizes - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: MapBodies - type_name: FileMapBodies - json_tag: mapBodies - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: For naming piped data - - name: ApiKeys - type_name: map[string]string - json_tag: apiKeys - omitempty: false - is_optional: false - is_array: false - is_map: true - comment: deprecated - - name: OpenAIBase - type_name: string - json_tag: openAIBase - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: deprecated - - name: OpenAIOrgId - type_name: string - json_tag: openAIOrgId - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: deprecated - - name: AuthVars - type_name: map[string]string - json_tag: authVars - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: SessionId - type_name: string - json_tag: sessionId - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 187 - is_exported: true - - name: LoadContextResponse - fields: - - name: TokensAdded - type_name: int - json_tag: tokensAdded - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TotalTokens - type_name: int - json_tag: totalTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MaxTokensExceeded - type_name: bool - json_tag: maxTokensExceeded - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MaxTokens - type_name: int - json_tag: maxTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Msg - type_name: string - json_tag: msg - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 214 - is_exported: true - - name: UpdateContextParams - fields: - - name: Body - type_name: string - json_tag: body - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: InputShas - type_name: map[string]string - json_tag: inputShas - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: InputTokens - type_name: map[string]int - json_tag: inputTokens - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: InputSizes - type_name: map[string]int64 - json_tag: inputSizes - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: MapBodies - type_name: FileMapBodies - json_tag: mapBodies - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: RemovedMapPaths - type_name: string - json_tag: removedMapPaths - omitempty: false - is_optional: false - is_array: true - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 222 - is_exported: true - - name: GetFileMapRequest - fields: - - name: MapInputs - type_name: FileMapInputs - json_tag: mapInputs - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 231 - is_exported: true - - name: GetFileMapResponse - fields: - - name: MapBodies - type_name: FileMapBodies - json_tag: mapBodies - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 235 - is_exported: true - - name: LoadCachedFileMapRequest - fields: - - name: FilePaths - type_name: string - json_tag: filePaths - omitempty: false - is_optional: false - is_array: true - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 239 - is_exported: true - - name: LoadCachedFileMapResponse - fields: - - name: LoadRes - type_name: LoadContextResponse - json_tag: loadRes - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: CachedByPath - type_name: map[string]bool - json_tag: cachedByPath - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 243 - is_exported: true - - name: GetContextBodyRequest - fields: - - name: ContextId - type_name: string - json_tag: contextId - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 248 - is_exported: true - - name: GetContextBodyResponse - fields: - - name: Body - type_name: string - json_tag: body - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 252 - is_exported: true - - name: DeleteContextRequest - fields: - - name: Ids - type_name: map[string]bool - json_tag: ids - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 260 - is_exported: true - - name: DeleteContextResponse - fields: - - name: TokensRemoved - type_name: int - json_tag: tokensRemoved - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TotalTokens - type_name: int - json_tag: totalTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Msg - type_name: string - json_tag: msg - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 264 - is_exported: true - - name: RejectFileRequest - fields: - - name: FilePath - type_name: string - json_tag: filePath - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 270 - is_exported: true - - name: RejectFilesRequest - fields: - - name: Paths - type_name: string - json_tag: paths - omitempty: false - is_optional: false - is_array: true - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 274 - is_exported: true - - name: RewindPlanRequest - fields: - - name: Sha - type_name: string - json_tag: sha - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 278 - is_exported: true - - name: RewindPlanResponse - fields: - - name: LatestSha - type_name: string - json_tag: latestSha - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: LatestCommit - type_name: string - json_tag: latestCommit - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 282 - is_exported: true - - name: LogResponse - fields: - - name: Shas - type_name: string - json_tag: shas - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: Body - type_name: string - json_tag: body - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 287 - is_exported: true - - name: CreateBranchRequest - fields: - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 292 - is_exported: true - - name: UpdateSettingsRequest - fields: - - name: ModelPackName - type_name: string - json_tag: modelPackName - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ModelPack - type_name: ModelPack - json_tag: modelPack - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 296 - is_exported: true - - name: UpdateSettingsResponse - fields: - - name: Msg - type_name: string - json_tag: msg - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 301 - is_exported: true - - name: UpdatePlanConfigRequest - fields: - - name: Config - type_name: PlanConfig - json_tag: config - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 305 - is_exported: true - - name: UpdateDefaultPlanConfigRequest - fields: - - name: Config - type_name: PlanConfig - json_tag: config - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 309 - is_exported: true - - name: GetPlanConfigResponse - fields: - - name: Config - type_name: PlanConfig - json_tag: config - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 313 - is_exported: true - - name: GetDefaultPlanConfigResponse - fields: - - name: Config - type_name: PlanConfig - json_tag: config - omitempty: false - is_optional: true - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 317 - is_exported: true - - name: ListUsersResponse - fields: - - name: Users - type_name: '*User' - json_tag: users - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: OrgUsersByUserId - type_name: map[string]*OrgUser - json_tag: orgUsersByUserId - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 321 - is_exported: true - - name: ApplyPlanRequest - fields: - - name: ApiKeys - type_name: map[string]string - json_tag: apiKeys - omitempty: false - is_optional: false - is_array: false - is_map: true - comment: deprecated - - name: OpenAIBase - type_name: string - json_tag: openAIBase - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: deprecated - - name: OpenAIOrgId - type_name: string - json_tag: openAIOrgId - omitempty: false - is_optional: false - is_array: false - is_map: false - comment: deprecated - - name: AuthVars - type_name: map[string]string - json_tag: authVars - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: SessionId - type_name: string - json_tag: sessionId - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 326 - is_exported: true - - name: RenamePlanRequest - fields: - - name: Name - type_name: string - json_tag: name - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 336 - is_exported: true - - name: GetBuildStatusResponse - fields: - - name: BuiltFiles - type_name: map[string]bool - json_tag: builtFiles - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: IsBuildingByPath - type_name: map[string]bool - json_tag: isBuildingByPath - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 340 - is_exported: true - - name: CreditsLogRequest - fields: - - name: TransactionType - type_name: CreditsTransactionType - json_tag: transactionType - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: PlanId - type_name: string - json_tag: planId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: SessionId - type_name: string - json_tag: sessionId - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: DayStart - type_name: time.Time - json_tag: dayStart - omitempty: false - is_optional: true - is_array: false - is_map: false - - name: Month - type_name: bool - json_tag: month - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 346 - is_exported: true - - name: CreditsLogResponse - fields: - - name: Transactions - type_name: '*CreditsTransaction' - json_tag: transactions - omitempty: false - is_optional: false - is_array: true - is_map: false - - name: NumPages - type_name: int - json_tag: numPages - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumPagesMax - type_name: bool - json_tag: numPagesMax - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MonthStart - type_name: time.Time - json_tag: monthStart - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: PlanNamesById - type_name: map[string]string - json_tag: planNamesById - omitempty: false - is_optional: false - is_array: false - is_map: true - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 354 - is_exported: true - - name: CreditsSummaryResponse - fields: - - name: Balance - type_name: decimal.Decimal - json_tag: balance - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: TotalSpend - type_name: decimal.Decimal - json_tag: totalSpend - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: MonthStart - type_name: time.Time - json_tag: monthStart - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ByPlanId - type_name: map[string]decimal.Decimal - json_tag: byPlanId - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: PlanNamesById - type_name: map[string]string - json_tag: planNamesById - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: ByModelName - type_name: map[string]decimal.Decimal - json_tag: byModelName - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: ByPurpose - type_name: map[string]decimal.Decimal - json_tag: byPurpose - omitempty: false - is_optional: false - is_array: false - is_map: true - - name: CacheSavings - type_name: decimal.Decimal - json_tag: cacheSavings - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 362 - is_exported: true - - name: GetBalanceResponse - fields: - - name: Balance - type_name: decimal.Decimal - json_tag: balance - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 378 - is_exported: true - enums: - - name: BuildMode - type_name: string - values: - - BuildModeAuto - - BuildModeNone - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 115 - - name: RespondMissingFileChoice - type_name: string - values: - - RespondMissingFileChoiceLoad - - RespondMissingFileChoiceSkip - - RespondMissingFileChoiceOverwrite - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 161 - type_aliases: - - name: BuildMode - underlying_type: string - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 113 - - name: RespondMissingFileChoice - underlying_type: string - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 159 - - name: FileMapInputs - underlying_type: map[string]string - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 173 - - name: LoadContextRequest - underlying_type: '[]*LoadContextParams' - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 212 - - name: UpdateContextRequest - underlying_type: map[string]*UpdateContextParams - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 256 - - name: UpdateContextResponse - underlying_type: '=' - file_path: /app/robot/../plandex/app/shared/req_res.go - line_number: 258 -stream: - package_name: shared - imports: [] - structs: - - name: BuildInfo - fields: - - name: Path - type_name: string - json_tag: path - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: NumTokens - type_name: int - json_tag: numTokens - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Finished - type_name: bool - json_tag: finished - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: Removed - type_name: bool - json_tag: removed - omitempty: true - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/stream.go - line_number: 5 - is_exported: true - - name: StreamMessage - fields: - - name: Type - type_name: StreamMessageType - json_tag: type - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: ReplyChunk - type_name: string - json_tag: replyChunk - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: BuildInfo - type_name: BuildInfo - json_tag: buildInfo - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: Description - type_name: ConvoMessageDescription - json_tag: description - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: Error - type_name: ApiError - json_tag: error - omitempty: true - is_optional: true - is_array: false - is_map: false - - name: MissingFilePath - type_name: string - json_tag: missingFilePath - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: MissingFileAutoContext - type_name: bool - json_tag: missingFileAutoContext - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: ModelStreamId - type_name: string - json_tag: modelStreamId - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: LoadContextFiles - type_name: string - json_tag: loadContextFiles - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: InitPrompt - type_name: string - json_tag: initPrompt - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: InitReplies - type_name: string - json_tag: initReplies - omitempty: true - is_optional: false - is_array: true - is_map: false - - name: InitBuildOnly - type_name: bool - json_tag: initBuildOnly - omitempty: true - is_optional: false - is_array: false - is_map: false - - name: StreamMessages - type_name: StreamMessage - json_tag: streamMessages - omitempty: true - is_optional: false - is_array: true - is_map: false - file_path: /app/robot/../plandex/app/shared/stream.go - line_number: 31 - is_exported: true - enums: - - name: StreamMessageType - type_name: string - values: - - StreamMessageStart - - StreamMessageConnectActive - - StreamMessageHeartbeat - - StreamMessageReply - - StreamMessageDescribing - - StreamMessageRepliesFinished - - StreamMessageBuildInfo - - StreamMessagePromptMissingFile - - StreamMessageLoadContext - - StreamMessageAborted - - StreamMessageFinished - - StreamMessageError - - StreamMessageMulti - file_path: /app/robot/../plandex/app/shared/stream.go - line_number: 14 - type_aliases: - - name: StreamMessageType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/stream.go - line_number: 12 -streamed_change: - package_name: shared - imports: - - fmt - - log - - strconv - - strings - structs: - - name: StreamedChangeSection - fields: - - name: StartLine - type_name: int - json_tag: startLine - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: EndLine - type_name: int - json_tag: endLine - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: StartLineString - type_name: string - json_tag: startLineString - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: EndLineString - type_name: string - json_tag: endLineString - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/streamed_change.go - line_number: 10 - is_exported: true - - name: StreamedChangeWithLineNums - fields: - - name: Old - type_name: StreamedChangeSection - json_tag: old - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: StartLineIncluded - type_name: bool - json_tag: startLineIncluded - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: EndLineIncluded - type_name: bool - json_tag: endLineIncluded - omitempty: false - is_optional: false - is_array: false - is_map: false - - name: New - type_name: string - json_tag: new - omitempty: false - is_optional: false - is_array: false - is_map: false - file_path: /app/robot/../plandex/app/shared/streamed_change.go - line_number: 17 - is_exported: true - enums: [] - type_aliases: [] -syntax: - package_name: shared - imports: - - path/filepath - - strings - structs: [] - enums: - - name: Language - type_name: string - values: - - LanguageBash - - LanguageC - - LanguageCpp - - LanguageCsharp - - LanguageCss - - LanguageCue - - LanguageDockerfile - - LanguageElixir - - LanguageElm - - LanguageGo - - LanguageGroovy - - LanguageHcl - - LanguageHtml - - LanguageJava - - LanguageJavascript - - LanguageJson - - LanguageKotlin - - LanguageLua - - LanguageOCaml - - LanguagePhp - - LanguageProtobuf - - LanguagePython - - LanguageRuby - - LanguageRust - - LanguageScala - - LanguageSvelte - - LanguageSwift - - LanguageToml - - LanguageTypescript - - LanguageJsx - - LanguageTsx - - LanguageYaml - - LanguageMarkdown - file_path: /app/robot/../plandex/app/shared/syntax.go - line_number: 10 - type_aliases: - - name: Language - underlying_type: string - file_path: /app/robot/../plandex/app/shared/syntax.go - line_number: 8 -utils: - package_name: shared - imports: - - bytes - - crypto/rand - - fmt - - regexp - - strings - - time - - unicode/utf8 - structs: [] - enums: [] - type_aliases: - - name: LineNumberedTextType - underlying_type: string - file_path: /app/robot/../plandex/app/shared/utils.go - line_number: 74 diff --git a/docs/reference/contracts/fixtures/ai_models_credentials_modelprovideroption_example.json b/docs/reference/contracts/fixtures/ai_models_credentials_modelprovideroption_example.json deleted file mode 100644 index 679f41b97..000000000 --- a/docs/reference/contracts/fixtures/ai_models_credentials_modelprovideroption_example.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "publishers": { - "key": "" - }, - "config": "", - "priority": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_custom_clientmodelpackschema_example.json b/docs/reference/contracts/fixtures/ai_models_custom_clientmodelpackschema_example.json deleted file mode 100644 index c865e2d06..000000000 --- a/docs/reference/contracts/fixtures/ai_models_custom_clientmodelpackschema_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "example_string", - "description": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_custom_clientmodelsinput_example.json b/docs/reference/contracts/fixtures/ai_models_custom_clientmodelsinput_example.json deleted file mode 100644 index 09c060edc..000000000 --- a/docs/reference/contracts/fixtures/ai_models_custom_clientmodelsinput_example.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "$schema": "", - "models": [ - "<*CustomModel>" - ], - "providers": [ - "<*CustomProvider>" - ], - "modelPacks": [ - "<*ClientModelPackSchema>" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_custom_custommodel_example.json b/docs/reference/contracts/fixtures/ai_models_custom_custommodel_example.json deleted file mode 100644 index dfe97f1bd..000000000 --- a/docs/reference/contracts/fixtures/ai_models_custom_custommodel_example.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "id": "example_string", - "modelId": "", - "publisher": "", - "description": "example_string", - "providers": [ - "" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_custom_customprovider_example.json b/docs/reference/contracts/fixtures/ai_models_custom_customprovider_example.json deleted file mode 100644 index 93ad8c573..000000000 --- a/docs/reference/contracts/fixtures/ai_models_custom_customprovider_example.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "id": "example_string", - "name": "example_string", - "baseUrl": "example_string", - "hasAWSAuth": true, - "skipAuth": true, - "apiKeyEnvVar": "example_string", - "extraAuthVars": [ - "" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_custom_modelsinput_example.json b/docs/reference/contracts/fixtures/ai_models_custom_modelsinput_example.json deleted file mode 100644 index a5f3f0d7d..000000000 --- a/docs/reference/contracts/fixtures/ai_models_custom_modelsinput_example.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "models": [ - "<*CustomModel>" - ], - "providers": [ - "<*CustomProvider>" - ], - "modelPacks": [ - "<*ModelPackSchema>" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_availablemodel_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_availablemodel_example.json deleted file mode 100644 index 8c2b3aeff..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_availablemodel_example.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "id": "example_string", - "description": "example_string", - "defaultMaxConvoTokens": 42, - "createdAt": "2024-01-01T00:00:00Z", - "updatedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfig_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfig_example.json deleted file mode 100644 index 4bbf2c45d..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfig_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "modelTag": "", - "modelId": "", - "publisher": "", - "basemodelshared": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfigschema_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfigschema_example.json deleted file mode 100644 index 5656ccad9..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfigschema_example.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "modelTag": "", - "modelId": "", - "publisher": "", - "description": "example_string", - "requiresVariantOverrides": [ - "example_string" - ], - "variants": [ - "" - ], - "providers": [ - "" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfigvariant_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfigvariant_example.json deleted file mode 100644 index 30514a7cb..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelconfigvariant_example.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "isBaseVariant": true, - "variantTag": "", - "description": "example_string", - "overrides": "", - "variants": [ - "" - ], - "requiresVariantOverrides": [ - "example_string" - ], - "isDefaultVariant": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelproviderconfig_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_basemodelproviderconfig_example.json deleted file mode 100644 index 980e5517a..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelproviderconfig_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "modelName": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelshared_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_basemodelshared_example.json deleted file mode 100644 index 2c5292670..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelshared_example.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "defaultMaxConvoTokens": 42, - "maxTokens": 42, - "maxOutputTokens": 42, - "reservedOutputTokens": 42, - "preferredOutputFormat": "", - "systemPromptDisabled": true, - "roleParamsDisabled": true, - "stopDisabled": true, - "predictedOutputEnabled": true, - "reasoningEffortEnabled": true, - "reasoningEffort": "", - "includeReasoning": true, - "hideReasoning": true, - "reasoningBudget": 42, - "supportsCacheControl": true, - "singleMessageNoSystemPrompt": true, - "tokenEstimatePaddingPct": 3.14159 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelusesprovider_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_basemodelusesprovider_example.json deleted file mode 100644 index 4babec871..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_basemodelusesprovider_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "provider": "", - "modelName": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_clientmodelpackschemaroles_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_clientmodelpackschemaroles_example.json deleted file mode 100644 index f90e94cf0..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_clientmodelpackschemaroles_example.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "$schema": "", - "localProvider": "", - "planner": "", - "architect": "", - "coder": "", - "summarizer": "", - "builder": "", - "wholeFileBuilder": "", - "names": "", - "commitMessages": "", - "autoContinue": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_modelcompatibility_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_modelcompatibility_example.json deleted file mode 100644 index e9dfa02f8..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_modelcompatibility_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "hasImageSupport": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_modelpack_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_modelpack_example.json deleted file mode 100644 index 7659ae0cb..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_modelpack_example.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "id": "example_string", - "name": "example_string", - "localProvider": "", - "description": "example_string", - "planner": "", - "coder": "", - "planSummary": "", - "builder": "", - "wholeFileBuilder": "", - "namer": "", - "commitMsg": "", - "execStatus": "", - "contextLoader": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_modelpackschema_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_modelpackschema_example.json deleted file mode 100644 index c865e2d06..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_modelpackschema_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "example_string", - "description": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_modelpackschemaroles_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_modelpackschemaroles_example.json deleted file mode 100644 index dc2af1524..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_modelpackschemaroles_example.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "localProvider": "", - "planner": "", - "planSummary": "", - "builder": "", - "namer": "", - "commitMsg": "", - "execStatus": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_modelroleconfig_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_modelroleconfig_example.json deleted file mode 100644 index a80cfa96b..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_modelroleconfig_example.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "role": "", - "modelId": "", - "temperature": 3.14, - "topP": 3.14, - "reservedOutputTokens": 42, - "largeContextFallback": "", - "largeOutputFallback": "", - "errorFallback": "", - "strongModel": "", - "localProvider": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_modelroleconfigschema_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_modelroleconfigschema_example.json deleted file mode 100644 index 7899db571..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_modelroleconfigschema_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "modelId": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_modelrolemodelconfig_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_modelrolemodelconfig_example.json deleted file mode 100644 index c72e7931b..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_modelrolemodelconfig_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "provider": "", - "modelTag": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_plannermodelconfig_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_plannermodelconfig_example.json deleted file mode 100644 index 195bf9bef..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_plannermodelconfig_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "maxConvoTokens": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_data_models_plannerroleconfig_example.json b/docs/reference/contracts/fixtures/ai_models_data_models_plannerroleconfig_example.json deleted file mode 100644 index 930629849..000000000 --- a/docs/reference/contracts/fixtures/ai_models_data_models_plannerroleconfig_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "modelroleconfig": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_errors_fallbackresult_example.json b/docs/reference/contracts/fixtures/ai_models_errors_fallbackresult_example.json deleted file mode 100644 index aa295d814..000000000 --- a/docs/reference/contracts/fixtures/ai_models_errors_fallbackresult_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "modelroleconfig": "", - "isfallback": true, - "fallbacktype": "", - "basemodelconfig": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_errors_modelerror_example.json b/docs/reference/contracts/fixtures/ai_models_errors_modelerror_example.json deleted file mode 100644 index 849b09509..000000000 --- a/docs/reference/contracts/fixtures/ai_models_errors_modelerror_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "kind": "", - "retriable": true, - "retryafterseconds": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_providers_modelproviderconfigschema_example.json b/docs/reference/contracts/fixtures/ai_models_providers_modelproviderconfigschema_example.json deleted file mode 100644 index a3beef8c8..000000000 --- a/docs/reference/contracts/fixtures/ai_models_providers_modelproviderconfigschema_example.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "provider": "", - "baseUrl": "example_string", - "hasAWSAuth": true, - "hasClaudeMaxAuth": true, - "skipAuth": true, - "localOnly": true, - "apiKeyEnvVar": "example_string", - "extraAuthVars": [ - "" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/ai_models_providers_modelproviderextraauthvars_example.json b/docs/reference/contracts/fixtures/ai_models_providers_modelproviderextraauthvars_example.json deleted file mode 100644 index 4c5296a29..000000000 --- a/docs/reference/contracts/fixtures/ai_models_providers_modelproviderextraauthvars_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "var": "example_string", - "maybeJSONFilePath": true, - "required": true, - "default": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/auth_apierror_example.json b/docs/reference/contracts/fixtures/auth_apierror_example.json deleted file mode 100644 index 867806afd..000000000 --- a/docs/reference/contracts/fixtures/auth_apierror_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "type": "", - "status": 42, - "msg": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/auth_authheader_example.json b/docs/reference/contracts/fixtures/auth_authheader_example.json deleted file mode 100644 index 1c2378f2b..000000000 --- a/docs/reference/contracts/fixtures/auth_authheader_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "token": "example_string", - "orgId": "example_string", - "hash": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/auth_billingerror_example.json b/docs/reference/contracts/fixtures/auth_billingerror_example.json deleted file mode 100644 index f56e1d3b4..000000000 --- a/docs/reference/contracts/fixtures/auth_billingerror_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "hasBillingPermission": true, - "isTrial": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/auth_clientaccount_example.json b/docs/reference/contracts/fixtures/auth_clientaccount_example.json deleted file mode 100644 index ac8027284..000000000 --- a/docs/reference/contracts/fixtures/auth_clientaccount_example.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "isCloud": true, - "host": "example_string", - "email": "example_string", - "userName": "example_string", - "userId": "example_string", - "token": "example_string", - "isLocalMode": true, - "isTrial": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/auth_clientauth_example.json b/docs/reference/contracts/fixtures/auth_clientauth_example.json deleted file mode 100644 index c648298c1..000000000 --- a/docs/reference/contracts/fixtures/auth_clientauth_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "orgId": "example_string", - "orgName": "example_string", - "orgIsTrial": true, - "integratedModelsMode": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/auth_trialmessagesexceedederror_example.json b/docs/reference/contracts/fixtures/auth_trialmessagesexceedederror_example.json deleted file mode 100644 index 62d83fe2c..000000000 --- a/docs/reference/contracts/fixtures/auth_trialmessagesexceedederror_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "maxMessages": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/auth_trialplansexceedederror_example.json b/docs/reference/contracts/fixtures/auth_trialplansexceedederror_example.json deleted file mode 100644 index b2fce9eed..000000000 --- a/docs/reference/contracts/fixtures/auth_trialplansexceedederror_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "maxPlans": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/context_contextupdateresult_example.json b/docs/reference/contracts/fixtures/context_contextupdateresult_example.json deleted file mode 100644 index 764dc1a32..000000000 --- a/docs/reference/contracts/fixtures/context_contextupdateresult_example.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "updatedcontexts": [ - "<*Context>" - ], - "tokendiffsbyid": { - "key": "" - }, - "tokensdiff": 42, - "totaltokens": 42, - "numfiles": 42, - "numurls": 42, - "numimages": 42, - "numtrees": 42, - "nummaps": 42, - "maxtokens": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/context_summaryforupdatecontextparams_example.json b/docs/reference/contracts/fixtures/context_summaryforupdatecontextparams_example.json deleted file mode 100644 index c27540379..000000000 --- a/docs/reference/contracts/fixtures/context_summaryforupdatecontextparams_example.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "numfiles": 42, - "numtrees": 42, - "numurls": 42, - "nummaps": 42, - "tokensdiff": 42, - "totaltokens": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_branch_example.json b/docs/reference/contracts/fixtures/data_models_branch_example.json deleted file mode 100644 index 6fe93b76c..000000000 --- a/docs/reference/contracts/fixtures/data_models_branch_example.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "id": "example_string", - "planId": "example_string", - "ownerId": "example_string", - "parentBranchId": "example_string", - "name": "example_string", - "status": "", - "contextTokens": 42, - "convoTokens": 42, - "createdAt": "2024-01-01T00:00:00Z", - "updatedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_cloudbillingfields_example.json b/docs/reference/contracts/fixtures/data_models_cloudbillingfields_example.json deleted file mode 100644 index 7440e57ff..000000000 --- a/docs/reference/contracts/fixtures/data_models_cloudbillingfields_example.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "creditsBalance": "", - "monthlyGrant": "", - "autoRebuyEnabled": true, - "autoRebuyMinThreshold": "", - "autoRebuyToBalance": "", - "notifyThreshold": "", - "maxThresholdPerMonth": "", - "billingCycleStartedAt": "2024-01-01T00:00:00Z", - "changedBillingMode": true, - "trialPaid": true, - "stripeSubscriptionId": "example_string", - "subscriptionStatus": "example_string", - "subscriptionPausedAt": "2024-01-01T00:00:00Z", - "stripePaymentMethod": "example_string", - "subscriptionActionRequired": true, - "subscriptionActionRequiredInvoiceUrl": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_context_example.json b/docs/reference/contracts/fixtures/data_models_context_example.json deleted file mode 100644 index 33498bc49..000000000 --- a/docs/reference/contracts/fixtures/data_models_context_example.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "id": "example_string", - "ownerId": "example_string", - "contextType": "", - "name": "example_string", - "url": "example_string", - "file_path": "example_string", - "sha": "example_string", - "numTokens": 42, - "body": "example_string", - "bodySize": 42, - "forceSkipIgnore": true, - "imageDetail": "", - "mapParts": "", - "mapShas": { - "key": "" - }, - "mapTokens": { - "key": "" - }, - "mapSizes": { - "key": "" - }, - "autoLoaded": true, - "createdAt": "2024-01-01T00:00:00Z", - "updatedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_convomessage_example.json b/docs/reference/contracts/fixtures/data_models_convomessage_example.json deleted file mode 100644 index d86e80f65..000000000 --- a/docs/reference/contracts/fixtures/data_models_convomessage_example.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "id": "example_string", - "userId": "example_string", - "role": "example_string", - "tokens": 42, - "num": 42, - "message": "example_string", - "stopped": true, - "flags": "", - "addedSubtasks": [ - "<*Subtask>" - ], - "removedSubtasks": [ - "example_string" - ], - "activeContextIds": [ - "example_string" - ], - "createdAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_convomessagedescription_example.json b/docs/reference/contracts/fixtures/data_models_convomessagedescription_example.json deleted file mode 100644 index 5a257fbf5..000000000 --- a/docs/reference/contracts/fixtures/data_models_convomessagedescription_example.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "id": "example_string", - "convoMessageId": "example_string", - "summarizedToMessageId": "example_string", - "wroteFiles": true, - "commitMsg": "example_string", - "operations": [ - "<*Operation>" - ], - "didBuild": true, - "buildPathsInvalidated": { - "key": "" - }, - "error": "example_string", - "createdAt": "2024-01-01T00:00:00Z", - "updatedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_convomessageflags_example.json b/docs/reference/contracts/fixtures/data_models_convomessageflags_example.json deleted file mode 100644 index d6375e778..000000000 --- a/docs/reference/contracts/fixtures/data_models_convomessageflags_example.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "didMakePlan": true, - "didRemoveTasks": true, - "didMakeDebuggingPlan": true, - "didLoadContext": true, - "currentstage": "", - "isChat": true, - "didWriteCode": true, - "didCompleteTask": true, - "didCompletePlan": true, - "hasUnfinishedSubtasks": true, - "isApplyDebug": true, - "isUserDebug": true, - "hasError": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_convosummary_example.json b/docs/reference/contracts/fixtures/data_models_convosummary_example.json deleted file mode 100644 index d6869d403..000000000 --- a/docs/reference/contracts/fixtures/data_models_convosummary_example.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "id": "example_string", - "latestConvoMessageCreatedAt": "2024-01-01T00:00:00Z", - "lastestConvoMessageId": "example_string", - "summary": "example_string", - "tokens": 42, - "numMessages": 42, - "createdAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_creditstransaction_example.json b/docs/reference/contracts/fixtures/data_models_creditstransaction_example.json deleted file mode 100644 index 0036fceeb..000000000 --- a/docs/reference/contracts/fixtures/data_models_creditstransaction_example.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "id": "example_string", - "orgId": "example_string", - "orgName": "example_string", - "userId": "example_string", - "userEmail": "example_string", - "userName": "example_string", - "transactionType": "", - "amount": "", - "startBalance": "", - "endBalance": "", - "creditIsAutoRebuy": true, - "createdAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_currentplanfiles_example.json b/docs/reference/contracts/fixtures/data_models_currentplanfiles_example.json deleted file mode 100644 index 1ae1fbffa..000000000 --- a/docs/reference/contracts/fixtures/data_models_currentplanfiles_example.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "files": { - "key": "" - }, - "removedByPath": { - "key": "" - }, - "updatedAtByPath": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_currentplanstate_example.json b/docs/reference/contracts/fixtures/data_models_currentplanstate_example.json deleted file mode 100644 index 776e41e19..000000000 --- a/docs/reference/contracts/fixtures/data_models_currentplanstate_example.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "planResult": "", - "currentPlanFiles": "", - "convoMessageDescriptions": [ - "<*ConvoMessageDescription>" - ], - "planApplies": [ - "<*PlanApply>" - ], - "contextsByPath": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_currentstage_example.json b/docs/reference/contracts/fixtures/data_models_currentstage_example.json deleted file mode 100644 index 857ee38b6..000000000 --- a/docs/reference/contracts/fixtures/data_models_currentstage_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "tellstage": "", - "planningphase": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_invite_example.json b/docs/reference/contracts/fixtures/data_models_invite_example.json deleted file mode 100644 index 60b4a88da..000000000 --- a/docs/reference/contracts/fixtures/data_models_invite_example.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "id": "example_string", - "orgId": "example_string", - "email": "example_string", - "name": "example_string", - "orgRoleId": "example_string", - "inviterId": "example_string", - "inviteeId": "example_string", - "acceptedAt": "2024-01-01T00:00:00Z", - "createdAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_operation_example.json b/docs/reference/contracts/fixtures/data_models_operation_example.json deleted file mode 100644 index 9885678c8..000000000 --- a/docs/reference/contracts/fixtures/data_models_operation_example.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "type": "", - "path": "example_string", - "destination": "example_string", - "content": "example_string", - "description": "example_string", - "replybefore": "example_string", - "numtokens": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_org_example.json b/docs/reference/contracts/fixtures/data_models_org_example.json deleted file mode 100644 index cb5c6cd4f..000000000 --- a/docs/reference/contracts/fixtures/data_models_org_example.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "id": "example_string", - "name": "example_string", - "isTrial": true, - "autoAddDomainUsers": true, - "integratedModelsMode": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_orgrole_example.json b/docs/reference/contracts/fixtures/data_models_orgrole_example.json deleted file mode 100644 index ce15a1f88..000000000 --- a/docs/reference/contracts/fixtures/data_models_orgrole_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "id": "example_string", - "isDefault": true, - "label": "example_string", - "description": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_orguser_example.json b/docs/reference/contracts/fixtures/data_models_orguser_example.json deleted file mode 100644 index 2ac1934cc..000000000 --- a/docs/reference/contracts/fixtures/data_models_orguser_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "orgId": "example_string", - "userId": "example_string", - "orgRoleId": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_plan_example.json b/docs/reference/contracts/fixtures/data_models_plan_example.json deleted file mode 100644 index 33328fe88..000000000 --- a/docs/reference/contracts/fixtures/data_models_plan_example.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "id": "example_string", - "ownerId": "example_string", - "projectId": "example_string", - "name": "example_string", - "totalReplies": 42, - "activeBranches": 42, - "createdAt": "2024-01-01T00:00:00Z", - "updatedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_planapply_example.json b/docs/reference/contracts/fixtures/data_models_planapply_example.json deleted file mode 100644 index aefd39bf9..000000000 --- a/docs/reference/contracts/fixtures/data_models_planapply_example.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "id": "example_string", - "userId": "example_string", - "convoMessageIds": [ - "example_string" - ], - "convoMessageDescriptionIds": [ - "example_string" - ], - "planFileResultIds": [ - "example_string" - ], - "commitMsg": "example_string", - "createdAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_planbuild_example.json b/docs/reference/contracts/fixtures/data_models_planbuild_example.json deleted file mode 100644 index 52c40d269..000000000 --- a/docs/reference/contracts/fixtures/data_models_planbuild_example.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "id": "example_string", - "convoMessageId": "example_string", - "filePath": "example_string", - "error": "example_string", - "createdAt": "2024-01-01T00:00:00Z", - "updatedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_planfileresult_example.json b/docs/reference/contracts/fixtures/data_models_planfileresult_example.json deleted file mode 100644 index c924624b8..000000000 --- a/docs/reference/contracts/fixtures/data_models_planfileresult_example.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "id": "example_string", - "typeVersion": 42, - "replaceWithLineNums": true, - "convoMessageId": "example_string", - "planBuildId": "example_string", - "path": "example_string", - "content": "example_string", - "anyFailed": true, - "replacements": [ - "<*Replacement>" - ], - "removedFile": true, - "createdAt": "2024-01-01T00:00:00Z", - "updatedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_planresult_example.json b/docs/reference/contracts/fixtures/data_models_planresult_example.json deleted file mode 100644 index d16c4c88c..000000000 --- a/docs/reference/contracts/fixtures/data_models_planresult_example.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "sortedPaths": [ - "example_string" - ], - "fileResultsByPath": "", - "results": [ - "<*PlanFileResult>" - ], - "replacementsByPath": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_project_example.json b/docs/reference/contracts/fixtures/data_models_project_example.json deleted file mode 100644 index 0929bdeac..000000000 --- a/docs/reference/contracts/fixtures/data_models_project_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "id": "example_string", - "name": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_replacement_example.json b/docs/reference/contracts/fixtures/data_models_replacement_example.json deleted file mode 100644 index 970adb245..000000000 --- a/docs/reference/contracts/fixtures/data_models_replacement_example.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "id": "example_string", - "old": "example_string", - "summary": "example_string", - "entireFile": true, - "new": "example_string", - "failed": true, - "streamedChange": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_subtask_example.json b/docs/reference/contracts/fixtures/data_models_subtask_example.json deleted file mode 100644 index e374f6172..000000000 --- a/docs/reference/contracts/fixtures/data_models_subtask_example.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "title": "example_string", - "description": "example_string", - "usesFiles": [ - "example_string" - ], - "isFinished": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/data_models_user_example.json b/docs/reference/contracts/fixtures/data_models_user_example.json deleted file mode 100644 index 22126c9e9..000000000 --- a/docs/reference/contracts/fixtures/data_models_user_example.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "id": "example_string", - "name": "example_string", - "email": "example_string", - "isTrial": true, - "numNonDraftPlans": 42 -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/org_user_config_orguserconfig_example.json b/docs/reference/contracts/fixtures/org_user_config_orguserconfig_example.json deleted file mode 100644 index 90bb19ef3..000000000 --- a/docs/reference/contracts/fixtures/org_user_config_orguserconfig_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "promptedClaudeMax": true, - "useClaudeSubscription": true, - "claudeSubscriptionCooldownStartedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/plan_config_configsetting_example.json b/docs/reference/contracts/fixtures/plan_config_configsetting_example.json deleted file mode 100644 index 6c1d8c05d..000000000 --- a/docs/reference/contracts/fixtures/plan_config_configsetting_example.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "name": "example_string", - "desc": "example_string", - "choices": [ - "example_string" - ], - "hascustomchoice": true, - "sortkey": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/plan_config_planconfig_example.json b/docs/reference/contracts/fixtures/plan_config_planconfig_example.json deleted file mode 100644 index b295bc6a3..000000000 --- a/docs/reference/contracts/fixtures/plan_config_planconfig_example.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "autoMode": "", - "editor": "example_string", - "editorCommand": "example_string", - "editorArgs": [ - "example_string" - ], - "editorOpenManually": true, - "autoContinue": true, - "autoBuild": true, - "autoUpdateContext": true, - "autoContext": true, - "smartContext": true, - "autoApply": true, - "autoCommit": true, - "skipCommit": true, - "canExec": true, - "autoExec": true, - "autoDebug": true, - "autoDebugTries": 42, - "autoRevertOnRewind": true, - "skipChangesMenu": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/plan_model_settings_plansettings_example.json b/docs/reference/contracts/fixtures/plan_model_settings_plansettings_example.json deleted file mode 100644 index 6e6355d77..000000000 --- a/docs/reference/contracts/fixtures/plan_model_settings_plansettings_example.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "modelPackName": "example_string", - "modelPack": "", - "customModelPacks": [ - "<*ModelPack>" - ], - "customModels": [ - "<*CustomModel>" - ], - "customModelsById": { - "key": "" - }, - "customProviders": [ - "<*CustomProvider>" - ], - "usesCustomProviderByModelId": { - "key": "" - }, - "isCloud": true, - "configured": true, - "updatedAt": "2024-01-01T00:00:00Z" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_applyplanrequest_example.json b/docs/reference/contracts/fixtures/req_res_applyplanrequest_example.json deleted file mode 100644 index 8e91bb4a6..000000000 --- a/docs/reference/contracts/fixtures/req_res_applyplanrequest_example.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "apiKeys": { - "key": "" - }, - "openAIBase": "example_string", - "openAIOrgId": "example_string", - "authVars": { - "key": "" - }, - "sessionId": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_buildplanrequest_example.json b/docs/reference/contracts/fixtures/req_res_buildplanrequest_example.json deleted file mode 100644 index bf4bebd05..000000000 --- a/docs/reference/contracts/fixtures/req_res_buildplanrequest_example.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "connectStream": true, - "apiKeys": { - "key": "" - }, - "openAIOrgId": "example_string", - "authVars": { - "key": "" - }, - "projectPaths": { - "key": "" - }, - "sessionId": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_converttrialrequest_example.json b/docs/reference/contracts/fixtures/req_res_converttrialrequest_example.json deleted file mode 100644 index e1bd174d1..000000000 --- a/docs/reference/contracts/fixtures/req_res_converttrialrequest_example.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "email": "example_string", - "pin": "example_string", - "userName": "example_string", - "orgName": "example_string", - "orgAutoAddDomainUsers": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createaccountrequest_example.json b/docs/reference/contracts/fixtures/req_res_createaccountrequest_example.json deleted file mode 100644 index 41916fe5b..000000000 --- a/docs/reference/contracts/fixtures/req_res_createaccountrequest_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "email": "example_string", - "pin": "example_string", - "userName": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createbranchrequest_example.json b/docs/reference/contracts/fixtures/req_res_createbranchrequest_example.json deleted file mode 100644 index 65d3b4603..000000000 --- a/docs/reference/contracts/fixtures/req_res_createbranchrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "name": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createemailverificationrequest_example.json b/docs/reference/contracts/fixtures/req_res_createemailverificationrequest_example.json deleted file mode 100644 index c82140a74..000000000 --- a/docs/reference/contracts/fixtures/req_res_createemailverificationrequest_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "email": "example_string", - "userId": "example_string", - "requireUser": true, - "requireNoUser": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createemailverificationresponse_example.json b/docs/reference/contracts/fixtures/req_res_createemailverificationresponse_example.json deleted file mode 100644 index 734722ab6..000000000 --- a/docs/reference/contracts/fixtures/req_res_createemailverificationresponse_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "hasAccount": true, - "isLocalMode": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createorgrequest_example.json b/docs/reference/contracts/fixtures/req_res_createorgrequest_example.json deleted file mode 100644 index 1bdbad4dd..000000000 --- a/docs/reference/contracts/fixtures/req_res_createorgrequest_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "name": "example_string", - "autoAddDomainUsers": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createorgresponse_example.json b/docs/reference/contracts/fixtures/req_res_createorgresponse_example.json deleted file mode 100644 index e01756912..000000000 --- a/docs/reference/contracts/fixtures/req_res_createorgresponse_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "id": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createplanrequest_example.json b/docs/reference/contracts/fixtures/req_res_createplanrequest_example.json deleted file mode 100644 index 65d3b4603..000000000 --- a/docs/reference/contracts/fixtures/req_res_createplanrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "name": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createplanresponse_example.json b/docs/reference/contracts/fixtures/req_res_createplanresponse_example.json deleted file mode 100644 index 0929bdeac..000000000 --- a/docs/reference/contracts/fixtures/req_res_createplanresponse_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "id": "example_string", - "name": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createprojectrequest_example.json b/docs/reference/contracts/fixtures/req_res_createprojectrequest_example.json deleted file mode 100644 index 65d3b4603..000000000 --- a/docs/reference/contracts/fixtures/req_res_createprojectrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "name": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_createprojectresponse_example.json b/docs/reference/contracts/fixtures/req_res_createprojectresponse_example.json deleted file mode 100644 index e01756912..000000000 --- a/docs/reference/contracts/fixtures/req_res_createprojectresponse_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "id": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_creditslogrequest_example.json b/docs/reference/contracts/fixtures/req_res_creditslogrequest_example.json deleted file mode 100644 index c51630676..000000000 --- a/docs/reference/contracts/fixtures/req_res_creditslogrequest_example.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "transactionType": "", - "planId": "example_string", - "sessionId": "example_string", - "dayStart": "2024-01-01T00:00:00Z", - "month": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_creditslogresponse_example.json b/docs/reference/contracts/fixtures/req_res_creditslogresponse_example.json deleted file mode 100644 index 57712a2e4..000000000 --- a/docs/reference/contracts/fixtures/req_res_creditslogresponse_example.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "transactions": [ - "<*CreditsTransaction>" - ], - "numPages": 42, - "numPagesMax": true, - "monthStart": "2024-01-01T00:00:00Z", - "planNamesById": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_creditssummaryresponse_example.json b/docs/reference/contracts/fixtures/req_res_creditssummaryresponse_example.json deleted file mode 100644 index 80d2f0147..000000000 --- a/docs/reference/contracts/fixtures/req_res_creditssummaryresponse_example.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "balance": "", - "totalSpend": "", - "monthStart": "2024-01-01T00:00:00Z", - "byPlanId": { - "key": "" - }, - "planNamesById": { - "key": "" - }, - "byModelName": { - "key": "" - }, - "byPurpose": { - "key": "" - }, - "cacheSavings": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_deletecontextrequest_example.json b/docs/reference/contracts/fixtures/req_res_deletecontextrequest_example.json deleted file mode 100644 index 7dd783bbd..000000000 --- a/docs/reference/contracts/fixtures/req_res_deletecontextrequest_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "ids": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_deletecontextresponse_example.json b/docs/reference/contracts/fixtures/req_res_deletecontextresponse_example.json deleted file mode 100644 index efcd5084c..000000000 --- a/docs/reference/contracts/fixtures/req_res_deletecontextresponse_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "tokensRemoved": 42, - "totalTokens": 42, - "msg": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getbalanceresponse_example.json b/docs/reference/contracts/fixtures/req_res_getbalanceresponse_example.json deleted file mode 100644 index 93606c59d..000000000 --- a/docs/reference/contracts/fixtures/req_res_getbalanceresponse_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "balance": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getbuildstatusresponse_example.json b/docs/reference/contracts/fixtures/req_res_getbuildstatusresponse_example.json deleted file mode 100644 index 54d5a9c84..000000000 --- a/docs/reference/contracts/fixtures/req_res_getbuildstatusresponse_example.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "builtFiles": { - "key": "" - }, - "isBuildingByPath": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getcontextbodyrequest_example.json b/docs/reference/contracts/fixtures/req_res_getcontextbodyrequest_example.json deleted file mode 100644 index 5764a4566..000000000 --- a/docs/reference/contracts/fixtures/req_res_getcontextbodyrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "contextId": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getcontextbodyresponse_example.json b/docs/reference/contracts/fixtures/req_res_getcontextbodyresponse_example.json deleted file mode 100644 index 5da2b39a1..000000000 --- a/docs/reference/contracts/fixtures/req_res_getcontextbodyresponse_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "body": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getcurrentbranchbyplanidrequest_example.json b/docs/reference/contracts/fixtures/req_res_getcurrentbranchbyplanidrequest_example.json deleted file mode 100644 index 72f620a04..000000000 --- a/docs/reference/contracts/fixtures/req_res_getcurrentbranchbyplanidrequest_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "currentBranchByPlanId": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getdefaultplanconfigresponse_example.json b/docs/reference/contracts/fixtures/req_res_getdefaultplanconfigresponse_example.json deleted file mode 100644 index 424bcf66b..000000000 --- a/docs/reference/contracts/fixtures/req_res_getdefaultplanconfigresponse_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "config": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getfilemaprequest_example.json b/docs/reference/contracts/fixtures/req_res_getfilemaprequest_example.json deleted file mode 100644 index 2a6e62a54..000000000 --- a/docs/reference/contracts/fixtures/req_res_getfilemaprequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "mapInputs": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getfilemapresponse_example.json b/docs/reference/contracts/fixtures/req_res_getfilemapresponse_example.json deleted file mode 100644 index 790f83923..000000000 --- a/docs/reference/contracts/fixtures/req_res_getfilemapresponse_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "mapBodies": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_getplanconfigresponse_example.json b/docs/reference/contracts/fixtures/req_res_getplanconfigresponse_example.json deleted file mode 100644 index 424bcf66b..000000000 --- a/docs/reference/contracts/fixtures/req_res_getplanconfigresponse_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "config": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_inviterequest_example.json b/docs/reference/contracts/fixtures/req_res_inviterequest_example.json deleted file mode 100644 index c99145bd2..000000000 --- a/docs/reference/contracts/fixtures/req_res_inviterequest_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "email": "example_string", - "name": "example_string", - "orgRoleId": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_listplansrunningresponse_example.json b/docs/reference/contracts/fixtures/req_res_listplansrunningresponse_example.json deleted file mode 100644 index 2df9e3fb8..000000000 --- a/docs/reference/contracts/fixtures/req_res_listplansrunningresponse_example.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "branches": [ - "<*Branch>" - ], - "streamStartedAtByBranchId": { - "key": "" - }, - "streamFinishedAtByBranchId": { - "key": "" - }, - "streamIdByBranchId": { - "key": "" - }, - "plansById": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_listusersresponse_example.json b/docs/reference/contracts/fixtures/req_res_listusersresponse_example.json deleted file mode 100644 index 125441c86..000000000 --- a/docs/reference/contracts/fixtures/req_res_listusersresponse_example.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "users": [ - "<*User>" - ], - "orgUsersByUserId": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_loadcachedfilemaprequest_example.json b/docs/reference/contracts/fixtures/req_res_loadcachedfilemaprequest_example.json deleted file mode 100644 index 4111625a2..000000000 --- a/docs/reference/contracts/fixtures/req_res_loadcachedfilemaprequest_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "filePaths": [ - "example_string" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_loadcachedfilemapresponse_example.json b/docs/reference/contracts/fixtures/req_res_loadcachedfilemapresponse_example.json deleted file mode 100644 index aa1b042b5..000000000 --- a/docs/reference/contracts/fixtures/req_res_loadcachedfilemapresponse_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "loadRes": "", - "cachedByPath": { - "key": "" - } -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_loadcontextparams_example.json b/docs/reference/contracts/fixtures/req_res_loadcontextparams_example.json deleted file mode 100644 index 6e1da8b4f..000000000 --- a/docs/reference/contracts/fixtures/req_res_loadcontextparams_example.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "contextType": "", - "name": "example_string", - "url": "example_string", - "file_path": "example_string", - "body": "example_string", - "forceSkipIgnore": true, - "imageDetail": "", - "autoLoaded": true, - "inputShas": { - "key": "" - }, - "inputTokens": { - "key": "" - }, - "inputSizes": { - "key": "" - }, - "mapBodies": "", - "apiKeys": { - "key": "" - }, - "openAIBase": "example_string", - "openAIOrgId": "example_string", - "authVars": { - "key": "" - }, - "sessionId": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_loadcontextresponse_example.json b/docs/reference/contracts/fixtures/req_res_loadcontextresponse_example.json deleted file mode 100644 index e02fb53a2..000000000 --- a/docs/reference/contracts/fixtures/req_res_loadcontextresponse_example.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "tokensAdded": 42, - "totalTokens": 42, - "maxTokensExceeded": true, - "maxTokens": 42, - "msg": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_logresponse_example.json b/docs/reference/contracts/fixtures/req_res_logresponse_example.json deleted file mode 100644 index 65ccdf2ce..000000000 --- a/docs/reference/contracts/fixtures/req_res_logresponse_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "shas": [ - "example_string" - ], - "body": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_rejectfilerequest_example.json b/docs/reference/contracts/fixtures/req_res_rejectfilerequest_example.json deleted file mode 100644 index a7172d8bd..000000000 --- a/docs/reference/contracts/fixtures/req_res_rejectfilerequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "filePath": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_rejectfilesrequest_example.json b/docs/reference/contracts/fixtures/req_res_rejectfilesrequest_example.json deleted file mode 100644 index 3cbbf65bd..000000000 --- a/docs/reference/contracts/fixtures/req_res_rejectfilesrequest_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "paths": [ - "example_string" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_renameplanrequest_example.json b/docs/reference/contracts/fixtures/req_res_renameplanrequest_example.json deleted file mode 100644 index 65d3b4603..000000000 --- a/docs/reference/contracts/fixtures/req_res_renameplanrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "name": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_renameprojectrequest_example.json b/docs/reference/contracts/fixtures/req_res_renameprojectrequest_example.json deleted file mode 100644 index 65d3b4603..000000000 --- a/docs/reference/contracts/fixtures/req_res_renameprojectrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "name": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_respondmissingfilerequest_example.json b/docs/reference/contracts/fixtures/req_res_respondmissingfilerequest_example.json deleted file mode 100644 index a34fa30a5..000000000 --- a/docs/reference/contracts/fixtures/req_res_respondmissingfilerequest_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "choice": "", - "filePath": "example_string", - "body": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_rewindplanrequest_example.json b/docs/reference/contracts/fixtures/req_res_rewindplanrequest_example.json deleted file mode 100644 index 68990c4be..000000000 --- a/docs/reference/contracts/fixtures/req_res_rewindplanrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "sha": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_rewindplanresponse_example.json b/docs/reference/contracts/fixtures/req_res_rewindplanresponse_example.json deleted file mode 100644 index 0b8c36931..000000000 --- a/docs/reference/contracts/fixtures/req_res_rewindplanresponse_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "latestSha": "example_string", - "latestCommit": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_sessionresponse_example.json b/docs/reference/contracts/fixtures/req_res_sessionresponse_example.json deleted file mode 100644 index a6b04d715..000000000 --- a/docs/reference/contracts/fixtures/req_res_sessionresponse_example.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "userId": "example_string", - "token": "example_string", - "email": "example_string", - "userName": "example_string", - "orgs": [ - "<*Org>" - ], - "isLocalMode": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_setprojectplanrequest_example.json b/docs/reference/contracts/fixtures/req_res_setprojectplanrequest_example.json deleted file mode 100644 index 90a2b5e58..000000000 --- a/docs/reference/contracts/fixtures/req_res_setprojectplanrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "planId": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_signinrequest_example.json b/docs/reference/contracts/fixtures/req_res_signinrequest_example.json deleted file mode 100644 index c26c4d155..000000000 --- a/docs/reference/contracts/fixtures/req_res_signinrequest_example.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "email": "example_string", - "pin": "example_string", - "isSignInCode": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_tellplanrequest_example.json b/docs/reference/contracts/fixtures/req_res_tellplanrequest_example.json deleted file mode 100644 index 58a33c112..000000000 --- a/docs/reference/contracts/fixtures/req_res_tellplanrequest_example.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "prompt": "example_string", - "buildMode": "", - "connectStream": true, - "autoContinue": true, - "isUserContinue": true, - "isUserDebug": true, - "isApplyDebug": true, - "isChatOnly": true, - "autoContext": true, - "smartContext": true, - "execEnabled": true, - "osDetails": "example_string", - "apiKeys": { - "key": "" - }, - "openAIOrgId": "example_string", - "authVars": { - "key": "" - }, - "projectPaths": { - "key": "" - }, - "isImplementationOfChat": true, - "isGitRepo": true, - "sessionId": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_uisignintoken_example.json b/docs/reference/contracts/fixtures/req_res_uisignintoken_example.json deleted file mode 100644 index abc9d8001..000000000 --- a/docs/reference/contracts/fixtures/req_res_uisignintoken_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "pin": "example_string", - "redirectTo": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_updatecontextparams_example.json b/docs/reference/contracts/fixtures/req_res_updatecontextparams_example.json deleted file mode 100644 index 4e380a69d..000000000 --- a/docs/reference/contracts/fixtures/req_res_updatecontextparams_example.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "body": "example_string", - "inputShas": { - "key": "" - }, - "inputTokens": { - "key": "" - }, - "inputSizes": { - "key": "" - }, - "mapBodies": "", - "removedMapPaths": [ - "example_string" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_updatedefaultplanconfigrequest_example.json b/docs/reference/contracts/fixtures/req_res_updatedefaultplanconfigrequest_example.json deleted file mode 100644 index 424bcf66b..000000000 --- a/docs/reference/contracts/fixtures/req_res_updatedefaultplanconfigrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "config": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_updateplanconfigrequest_example.json b/docs/reference/contracts/fixtures/req_res_updateplanconfigrequest_example.json deleted file mode 100644 index 424bcf66b..000000000 --- a/docs/reference/contracts/fixtures/req_res_updateplanconfigrequest_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "config": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_updatesettingsrequest_example.json b/docs/reference/contracts/fixtures/req_res_updatesettingsrequest_example.json deleted file mode 100644 index 71887b353..000000000 --- a/docs/reference/contracts/fixtures/req_res_updatesettingsrequest_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "modelPackName": "example_string", - "modelPack": "" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_updatesettingsresponse_example.json b/docs/reference/contracts/fixtures/req_res_updatesettingsresponse_example.json deleted file mode 100644 index a15aad1ed..000000000 --- a/docs/reference/contracts/fixtures/req_res_updatesettingsresponse_example.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "msg": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/req_res_verifyemailpinrequest_example.json b/docs/reference/contracts/fixtures/req_res_verifyemailpinrequest_example.json deleted file mode 100644 index 9fe944f40..000000000 --- a/docs/reference/contracts/fixtures/req_res_verifyemailpinrequest_example.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "email": "example_string", - "pin": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/stream_buildinfo_example.json b/docs/reference/contracts/fixtures/stream_buildinfo_example.json deleted file mode 100644 index dd9060820..000000000 --- a/docs/reference/contracts/fixtures/stream_buildinfo_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "path": "example_string", - "numTokens": 42, - "finished": true, - "removed": true -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/stream_streammessage_example.json b/docs/reference/contracts/fixtures/stream_streammessage_example.json deleted file mode 100644 index c5ce184a1..000000000 --- a/docs/reference/contracts/fixtures/stream_streammessage_example.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "type": "", - "replyChunk": "example_string", - "missingFilePath": "example_string", - "missingFileAutoContext": true, - "modelStreamId": "example_string", - "loadContextFiles": [ - "example_string" - ], - "initPrompt": "example_string", - "initReplies": [ - "example_string" - ], - "initBuildOnly": true, - "streamMessages": [ - "" - ] -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/streamed_change_streamedchangesection_example.json b/docs/reference/contracts/fixtures/streamed_change_streamedchangesection_example.json deleted file mode 100644 index 5e98a4a3d..000000000 --- a/docs/reference/contracts/fixtures/streamed_change_streamedchangesection_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "startLine": 42, - "endLine": 42, - "startLineString": "example_string", - "endLineString": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/fixtures/streamed_change_streamedchangewithlinenums_example.json b/docs/reference/contracts/fixtures/streamed_change_streamedchangewithlinenums_example.json deleted file mode 100644 index 16c43952d..000000000 --- a/docs/reference/contracts/fixtures/streamed_change_streamedchangewithlinenums_example.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "old": "", - "startLineIncluded": true, - "endLineIncluded": true, - "new": "example_string" -} \ No newline at end of file diff --git a/docs/reference/contracts/stubs/ai_models_credentials.py b/docs/reference/contracts/stubs/ai_models_credentials.py deleted file mode 100644 index 6bd2daab4..000000000 --- a/docs/reference/contracts/stubs/ai_models_credentials.py +++ /dev/null @@ -1,17 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -ModelProviderOptions = map[string]ModelProviderOption - -@dataclass -class ModelProviderOption: - """Data contract for ModelProviderOption.""" - - publishers: Dict[str, map[ModelPublisher]bool] = field(default_factory=dict) - config: Optional[ModelProviderConfigSchema] = None - priority: int diff --git a/docs/reference/contracts/stubs/ai_models_custom.py b/docs/reference/contracts/stubs/ai_models_custom.py deleted file mode 100644 index dc979d1e5..000000000 --- a/docs/reference/contracts/stubs/ai_models_custom.py +++ /dev/null @@ -1,69 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class SchemaUrl(str, Enum): - """Enum for SchemaUrl.""" - - SchemaUrlInputConfig = "SchemaUrlInputConfig" - SchemaUrlPlanConfig = "SchemaUrlPlanConfig" - SchemaUrlInlineModelPack = "SchemaUrlInlineModelPack" - - -SchemaUrl = str - -@dataclass -class CustomModel: - """Data contract for CustomModel.""" - - id: str = None - modelId: ModelId - publisher: ModelPublisher - description: str - providers: List[BaseModelUsesProvider] = field(default_factory=list) - createdAt: Optional[Time] = None - updatedAt: Optional[Time] = None - -@dataclass -class CustomProvider: - """Data contract for CustomProvider.""" - - id: str = None - name: str - # for AWS Bedrock models - baseUrl: str - # for local models that don't require auth (ollama, etc.) - hasAWSAuth: bool = None - skipAuth: bool = None - apiKeyEnvVar: str = None - extraAuthVars: List[ModelProviderExtraAuthVars] = None - createdAt: Optional[Time] = None - updatedAt: Optional[Time] = None - -@dataclass -class ModelsInput: - """Data contract for ModelsInput.""" - - models: List[*CustomModel] = None - providers: List[*CustomProvider] = None - modelPacks: List[*ModelPackSchema] = None - -@dataclass -class ClientModelPackSchema: - """Data contract for ClientModelPackSchema.""" - - name: str - description: str - -@dataclass -class ClientModelsInput: - """Data contract for ClientModelsInput.""" - - $schema: SchemaUrl - models: List[*CustomModel] = None - providers: List[*CustomProvider] = None - modelPacks: List[*ClientModelPackSchema] = None diff --git a/docs/reference/contracts/stubs/ai_models_data_models.py b/docs/reference/contracts/stubs/ai_models_data_models.py deleted file mode 100644 index 31e84bed4..000000000 --- a/docs/reference/contracts/stubs/ai_models_data_models.py +++ /dev/null @@ -1,232 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class ModelOutputFormat(str, Enum): - """Enum for ModelOutputFormat.""" - - ModelOutputFormatToolCallJson = "ModelOutputFormatToolCallJson" - ModelOutputFormatXml = "ModelOutputFormatXml" - - -class ReasoningEffort(str, Enum): - """Enum for ReasoningEffort.""" - - ReasoningEffortLow = "ReasoningEffortLow" - ReasoningEffortMedium = "ReasoningEffortMedium" - ReasoningEffortHigh = "ReasoningEffortHigh" - - -ModelOutputFormat = str - -ModelName = str - -ModelId = str - -ModelTag = str - -VariantTag = str - -ReasoningEffort = str - -RoleJSON = Any - -@dataclass -class ModelCompatibility: - """Data contract for ModelCompatibility.""" - - hasImageSupport: bool - -@dataclass -class BaseModelShared: - """Data contract for BaseModelShared.""" - - defaultMaxConvoTokens: int - maxTokens: int - maxOutputTokens: int - reservedOutputTokens: int - preferredOutputFormat: ModelOutputFormat - systemPromptDisabled: bool = None - roleParamsDisabled: bool = None - stopDisabled: bool = None - predictedOutputEnabled: bool = None - reasoningEffortEnabled: bool = None - reasoningEffort: ReasoningEffort = None - includeReasoning: bool = None - hideReasoning: bool = None - reasoningBudget: int = None - supportsCacheControl: bool = None - singleMessageNoSystemPrompt: bool = None - tokenEstimatePaddingPct: float = None - -@dataclass -class BaseModelProviderConfig: - """Data contract for BaseModelProviderConfig.""" - - modelName: ModelName - -@dataclass -class BaseModelConfig: - """Data contract for BaseModelConfig.""" - - modelTag: ModelTag - modelId: ModelId - publisher: ModelPublisher = None - basemodelshared: BaseModelProviderConfig - -@dataclass -class BaseModelUsesProvider: - """Data contract for BaseModelUsesProvider.""" - - provider: ModelProvider - customProvider: Optional[str] = None - modelName: ModelName - -@dataclass -class BaseModelConfigSchema: - """Data contract for BaseModelConfigSchema.""" - - modelTag: ModelTag - modelId: ModelId - publisher: ModelPublisher - description: str - requiresVariantOverrides: List[str] = field(default_factory=list) - variants: List[BaseModelConfigVariant] = field(default_factory=list) - providers: List[BaseModelUsesProvider] = field(default_factory=list) - -@dataclass -class BaseModelConfigVariant: - """Data contract for BaseModelConfigVariant.""" - - isBaseVariant: bool - variantTag: VariantTag - description: str - overrides: BaseModelShared - variants: List[BaseModelConfigVariant] = field(default_factory=list) - requiresVariantOverrides: List[str] = field(default_factory=list) - isDefaultVariant: bool - -@dataclass -class AvailableModel: - """Data contract for AvailableModel.""" - - id: str - description: str - defaultMaxConvoTokens: int - createdAt: Time - updatedAt: Time - -@dataclass -class PlannerModelConfig: - """Data contract for PlannerModelConfig.""" - - maxConvoTokens: int - -@dataclass -class ModelRoleConfig: - """Data contract for ModelRoleConfig.""" - - role: ModelRole - # new in 2.2.0 refactor — uses provider lookup instead of BaseModelConfig and MissingKeyFallback - modelId: ModelId - baseModelConfig: Optional[BaseModelConfig] = None - temperature: float - topP: float - reservedOutputTokens: int - largeContextFallback: Optional[ModelRoleConfig] = None - largeOutputFallback: Optional[ModelRoleConfig] = None - # MissingKeyFallback *ModelRoleConfig // removed in 2.2.0 refactor — - errorFallback: Optional[ModelRoleConfig] = None - strongModel: Optional[ModelRoleConfig] = None - localProvider: ModelProvider = None - -@dataclass -class ModelRoleModelConfig: - """Data contract for ModelRoleModelConfig.""" - - provider: ModelProvider - customProvider: Optional[str] = None - modelTag: ModelTag - -@dataclass -class ModelRoleConfigSchema: - """Data contract for ModelRoleConfigSchema.""" - - modelId: ModelId - temperature: Optional[float] = None - topP: Optional[float] = None - reservedOutputTokens: Optional[int] = None - maxConvoTokens: Optional[int] = None - largeContextFallback: Optional[ModelRoleConfigSchema] = None - largeOutputFallback: Optional[ModelRoleConfigSchema] = None - errorFallback: Optional[ModelRoleConfigSchema] = None - strongModel: Optional[ModelRoleConfigSchema] = None - -@dataclass -class PlannerRoleConfig: - """Data contract for PlannerRoleConfig.""" - - modelroleconfig: PlannerModelConfig - -@dataclass -class ClientModelPackSchemaRoles: - """Data contract for ClientModelPackSchemaRoles.""" - - $schema: SchemaUrl = None - # in the JSON, these can either be a role as a string or a ModelRoleConfigSchema object for more complex config - localProvider: ModelProvider = None - planner: RoleJSON - architect: RoleJSON = None - coder: RoleJSON = None - summarizer: RoleJSON - builder: RoleJSON - wholeFileBuilder: RoleJSON = None - names: RoleJSON - commitMessages: RoleJSON - autoContinue: RoleJSON - -@dataclass -class ModelPackSchemaRoles: - """Data contract for ModelPackSchemaRoles.""" - - localProvider: ModelProvider = None - planner: ModelRoleConfigSchema - coder: Optional[ModelRoleConfigSchema] = None - planSummary: ModelRoleConfigSchema - builder: ModelRoleConfigSchema - # optional, defaults to builder model — access via GetWholeFileBuilder() - wholeFileBuilder: Optional[ModelRoleConfigSchema] = None - namer: ModelRoleConfigSchema - commitMsg: ModelRoleConfigSchema - execStatus: ModelRoleConfigSchema - contextLoader: Optional[ModelRoleConfigSchema] = None - -@dataclass -class ModelPackSchema: - """Data contract for ModelPackSchema.""" - - name: str - description: str - -@dataclass -class ModelPack: - """Data contract for ModelPack.""" - - id: str - name: str - localProvider: ModelProvider = None - description: str - planner: PlannerRoleConfig - coder: Optional[ModelRoleConfig] = None - planSummary: ModelRoleConfig - builder: ModelRoleConfig - # optional, defaults to builder model — access via GetWholeFileBuilder() - wholeFileBuilder: Optional[ModelRoleConfig] = None - namer: ModelRoleConfig - commitMsg: ModelRoleConfig - execStatus: ModelRoleConfig - contextLoader: Optional[ModelRoleConfig] = None diff --git a/docs/reference/contracts/stubs/ai_models_errors.py b/docs/reference/contracts/stubs/ai_models_errors.py deleted file mode 100644 index 84571a389..000000000 --- a/docs/reference/contracts/stubs/ai_models_errors.py +++ /dev/null @@ -1,47 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class ModelErrKind(str, Enum): - """Enum for ModelErrKind.""" - - ErrOverloaded = "ErrOverloaded" - ErrContextTooLong = "ErrContextTooLong" - ErrRateLimited = "ErrRateLimited" - ErrSubscriptionQuotaExhausted = "ErrSubscriptionQuotaExhausted" - ErrOther = "ErrOther" - ErrCacheSupport = "ErrCacheSupport" - - -class FallbackType(str, Enum): - """Enum for FallbackType.""" - - FallbackTypeError = "FallbackTypeError" - FallbackTypeContext = "FallbackTypeContext" - FallbackTypeProvider = "FallbackTypeProvider" - - -ModelErrKind = str - -FallbackType = str - -@dataclass -class ModelError: - """Data contract for ModelError.""" - - kind: ModelErrKind - retriable: bool - retryafterseconds: int - -@dataclass -class FallbackResult: - """Data contract for FallbackResult.""" - - modelroleconfig: Optional[ModelRoleConfig] = None - isfallback: bool - fallbacktype: FallbackType - basemodelconfig: Optional[BaseModelConfig] = None diff --git a/docs/reference/contracts/stubs/ai_models_openrouter.py b/docs/reference/contracts/stubs/ai_models_openrouter.py deleted file mode 100644 index 110b64b8f..000000000 --- a/docs/reference/contracts/stubs/ai_models_openrouter.py +++ /dev/null @@ -1,19 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class OpenRouterFamily(str, Enum): - """Enum for OpenRouterFamily.""" - - OpenRouterFamilyAnthropic = "OpenRouterFamilyAnthropic" - OpenRouterFamilyGoogle = "OpenRouterFamilyGoogle" - OpenRouterFamilyOpenAI = "OpenRouterFamilyOpenAI" - OpenRouterFamilyQwen = "OpenRouterFamilyQwen" - OpenRouterFamilyDeepSeek = "OpenRouterFamilyDeepSeek" - - -OpenRouterFamily = str diff --git a/docs/reference/contracts/stubs/ai_models_providers.py b/docs/reference/contracts/stubs/ai_models_providers.py deleted file mode 100644 index 5bec3eb47..000000000 --- a/docs/reference/contracts/stubs/ai_models_providers.py +++ /dev/null @@ -1,66 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class ModelPublisher(str, Enum): - """Enum for ModelPublisher.""" - - ModelPublisherOpenAI = "ModelPublisherOpenAI" - ModelPublisherAnthropic = "ModelPublisherAnthropic" - ModelPublisherGoogle = "ModelPublisherGoogle" - ModelPublisherDeepSeek = "ModelPublisherDeepSeek" - ModelPublisherPerplexity = "ModelPublisherPerplexity" - ModelPublisherQwen = "ModelPublisherQwen" - ModelPublisherMistral = "ModelPublisherMistral" - - -class ModelProvider(str, Enum): - """Enum for ModelProvider.""" - - ModelProviderOpenRouter = "ModelProviderOpenRouter" - ModelProviderOpenAI = "ModelProviderOpenAI" - ModelProviderAnthropic = "ModelProviderAnthropic" - ModelProviderAnthropicClaudeMax = "ModelProviderAnthropicClaudeMax" - ModelProviderGoogleAIStudio = "ModelProviderGoogleAIStudio" - ModelProviderGoogleVertex = "ModelProviderGoogleVertex" - ModelProviderAzureOpenAI = "ModelProviderAzureOpenAI" - ModelProviderDeepSeek = "ModelProviderDeepSeek" - ModelProviderPerplexity = "ModelProviderPerplexity" - ModelProviderAmazonBedrock = "ModelProviderAmazonBedrock" - ModelProviderOllama = "ModelProviderOllama" - ModelProviderCustom = "ModelProviderCustom" - - -ModelPublisher = str - -ModelProvider = str - -@dataclass -class ModelProviderExtraAuthVars: - """Data contract for ModelProviderExtraAuthVars.""" - - var: str - maybeJSONFilePath: bool = None - required: bool = None - default: str = None - -@dataclass -class ModelProviderConfigSchema: - """Data contract for ModelProviderConfigSchema.""" - - provider: ModelProvider - customProvider: Optional[str] = None - # for AWS Bedrock models - baseUrl: str - # for Claude Max integration - hasAWSAuth: bool = None - # for local models that don't require auth (ollama, etc.) - hasClaudeMaxAuth: bool = None - skipAuth: bool = None - localOnly: bool = None - apiKeyEnvVar: str = None - extraAuthVars: List[ModelProviderExtraAuthVars] = None diff --git a/docs/reference/contracts/stubs/ai_models_roles.py b/docs/reference/contracts/stubs/ai_models_roles.py deleted file mode 100644 index e153da6fe..000000000 --- a/docs/reference/contracts/stubs/ai_models_roles.py +++ /dev/null @@ -1,23 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class ModelRole(str, Enum): - """Enum for ModelRole.""" - - ModelRolePlanner = "ModelRolePlanner" - ModelRoleCoder = "ModelRoleCoder" - ModelRoleArchitect = "ModelRoleArchitect" - ModelRolePlanSummary = "ModelRolePlanSummary" - ModelRoleBuilder = "ModelRoleBuilder" - ModelRoleWholeFileBuilder = "ModelRoleWholeFileBuilder" - ModelRoleName = "ModelRoleName" - ModelRoleCommitMsg = "ModelRoleCommitMsg" - ModelRoleExecStatus = "ModelRoleExecStatus" - - -ModelRole = str diff --git a/docs/reference/contracts/stubs/auth.py b/docs/reference/contracts/stubs/auth.py deleted file mode 100644 index cb68a0253..000000000 --- a/docs/reference/contracts/stubs/auth.py +++ /dev/null @@ -1,89 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class ApiErrorType(str, Enum): - """Enum for ApiErrorType.""" - - ApiErrorTypeInvalidToken = "ApiErrorTypeInvalidToken" - ApiErrorTypeAuthOutdated = "ApiErrorTypeAuthOutdated" - ApiErrorTypeTrialPlansExceeded = "ApiErrorTypeTrialPlansExceeded" - ApiErrorTypeTrialMessagesExceeded = "ApiErrorTypeTrialMessagesExceeded" - ApiErrorTypeTrialActionNotAllowed = "ApiErrorTypeTrialActionNotAllowed" - ApiErrorTypeContinueNoMessages = "ApiErrorTypeContinueNoMessages" - ApiErrorTypeCloudInsufficientCredits = "ApiErrorTypeCloudInsufficientCredits" - ApiErrorTypeCloudMonthlyMaxReached = "ApiErrorTypeCloudMonthlyMaxReached" - ApiErrorTypeCloudSubscriptionPaused = "ApiErrorTypeCloudSubscriptionPaused" - ApiErrorTypeCloudSubscriptionOverdue = "ApiErrorTypeCloudSubscriptionOverdue" - ApiErrorTypeOther = "ApiErrorTypeOther" - - -ApiErrorType = str - -@dataclass -class AuthHeader: - """Data contract for AuthHeader.""" - - token: str - orgId: str - hash: str - -@dataclass -class TrialPlansExceededError: - """Data contract for TrialPlansExceededError.""" - - maxPlans: int - -@dataclass -class TrialMessagesExceededError: - """Data contract for TrialMessagesExceededError.""" - - maxMessages: int - -@dataclass -class BillingError: - """Data contract for BillingError.""" - - hasBillingPermission: bool - isTrial: bool - -@dataclass -class ApiError: - """Data contract for ApiError.""" - - type_: ApiErrorType - status: int - # only used for trial plans exceeded error - msg: str - # only used for trial messages exceeded error - trialPlansExceededError: Optional[TrialPlansExceededError] = None - # only used for billing errors - trialMessagesExceededError: Optional[TrialMessagesExceededError] = None - billingError: Optional[BillingError] = None - -@dataclass -class ClientAccount: - """Data contract for ClientAccount.""" - - isCloud: bool - host: str - email: str - userName: str - userId: str - token: str - isLocalMode: bool - # legacy field - isTrial: bool - -@dataclass -class ClientAuth: - """Data contract for ClientAuth.""" - - orgId: str - orgName: str - orgIsTrial: bool - integratedModelsMode: bool diff --git a/docs/reference/contracts/stubs/context.py b/docs/reference/contracts/stubs/context.py deleted file mode 100644 index 0cdafbd5d..000000000 --- a/docs/reference/contracts/stubs/context.py +++ /dev/null @@ -1,39 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class MaxContextCount(str, Enum): - """Enum for MaxContextCount.""" - - 25MB = "25MB" - - -@dataclass -class ContextUpdateResult: - """Data contract for ContextUpdateResult.""" - - updatedcontexts: List[*Context] = field(default_factory=list) - tokendiffsbyid: Dict[str, map[string]int] = field(default_factory=dict) - tokensdiff: int - totaltokens: int - numfiles: int - numurls: int - numimages: int - numtrees: int - nummaps: int - maxtokens: int - -@dataclass -class SummaryForUpdateContextParams: - """Data contract for SummaryForUpdateContextParams.""" - - numfiles: int - numtrees: int - numurls: int - nummaps: int - tokensdiff: int - totaltokens: int diff --git a/docs/reference/contracts/stubs/data_models.py b/docs/reference/contracts/stubs/data_models.py deleted file mode 100644 index e894d867e..000000000 --- a/docs/reference/contracts/stubs/data_models.py +++ /dev/null @@ -1,428 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class ContextType(str, Enum): - """Enum for ContextType.""" - - ContextFileType = "ContextFileType" - ContextURLType = "ContextURLType" - ContextNoteType = "ContextNoteType" - ContextDirectoryTreeType = "ContextDirectoryTreeType" - ContextPipedDataType = "ContextPipedDataType" - ContextImageType = "ContextImageType" - ContextMapType = "ContextMapType" - - -class TellStage(str, Enum): - """Enum for TellStage.""" - - TellStagePlanning = "TellStagePlanning" - TellStageImplementation = "TellStageImplementation" - - -class PlanningPhase(str, Enum): - """Enum for PlanningPhase.""" - - PlanningPhaseContext = "PlanningPhaseContext" - PlanningPhaseTasks = "PlanningPhaseTasks" - - -class OperationType(str, Enum): - """Enum for OperationType.""" - - OperationTypeFile = "OperationTypeFile" - OperationTypeMove = "OperationTypeMove" - OperationTypeRemove = "OperationTypeRemove" - OperationTypeReset = "OperationTypeReset" - - -class CreditsTransactionType(str, Enum): - """Enum for CreditsTransactionType.""" - - CreditsTransactionTypeCredit = "CreditsTransactionTypeCredit" - CreditsTransactionTypeDebit = "CreditsTransactionTypeDebit" - - -class CreditType(str, Enum): - """Enum for CreditType.""" - - CreditTypeTrial = "CreditTypeTrial" - CreditTypeGrant = "CreditTypeGrant" - CreditTypeAdminGrant = "CreditTypeAdminGrant" - CreditTypePurchase = "CreditTypePurchase" - CreditTypeSwitch = "CreditTypeSwitch" - - -ContextType = str - -FileMapBodies = map[string]string - -TellStage = str - -PlanningPhase = str - -OperationType = str - -PlanFileResultsByPath = map[string][]*PlanFileResult - -CreditsTransactionType = str - -CreditType = str - -@dataclass -class Org: - """Data contract for Org.""" - - id: str - name: str - isTrial: bool - # optional cloud attributes - autoAddDomainUsers: bool - integratedModelsMode: bool = None - cloudBillingFields: Optional[CloudBillingFields] = None - -@dataclass -class User: - """Data contract for User.""" - - id: str - name: str - email: str - isTrial: bool - numNonDraftPlans: int - defaultPlanConfig: Optional[PlanConfig] = None - -@dataclass -class OrgUser: - """Data contract for OrgUser.""" - - orgId: str - userId: str - orgRoleId: str - config: Optional[OrgUserConfig] = None - -@dataclass -class Invite: - """Data contract for Invite.""" - - id: str - orgId: str - email: str - name: str - orgRoleId: str - inviterId: str - inviteeId: Optional[str] = None - acceptedAt: Optional[Time] = None - createdAt: Time - -@dataclass -class Project: - """Data contract for Project.""" - - id: str - name: str - -@dataclass -class Plan: - """Data contract for Plan.""" - - id: str - ownerId: str - projectId: str - name: str - sharedWithOrgAt: Optional[Time] = None - totalReplies: int - activeBranches: int - planConfig: Optional[PlanConfig] = None - archivedAt: Optional[Time] = None - createdAt: Time - updatedAt: Time - -@dataclass -class Branch: - """Data contract for Branch.""" - - id: str - planId: str - ownerId: str - parentBranchId: Optional[str] = None - name: str - status: PlanStatus - contextTokens: int - convoTokens: int - sharedWithOrgAt: Optional[Time] = None - archivedAt: Optional[Time] = None - createdAt: Time - updatedAt: Time - -@dataclass -class Context: - """Data contract for Context.""" - - id: str - ownerId: str - contextType: ContextType - name: str - url: str - file_path: str - sha: str - numTokens: int - body: str = None - bodySize: int = None - forceSkipIgnore: bool - imageDetail: ImageURLDetail = None - mapParts: FileMapBodies = None - mapShas: Dict[str, map[string]string] = None - mapTokens: Dict[str, map[string]int] = None - mapSizes: Dict[str, map[string]int64] = None - autoLoaded: bool - createdAt: Time - updatedAt: Time - -@dataclass -class CurrentStage: - """Data contract for CurrentStage.""" - - tellstage: TellStage - planningphase: PlanningPhase - -@dataclass -class ConvoMessageFlags: - """Data contract for ConvoMessageFlags.""" - - didMakePlan: bool - didRemoveTasks: bool - didMakeDebuggingPlan: bool - didLoadContext: bool - currentstage: CurrentStage - isChat: bool - didWriteCode: bool - didCompleteTask: bool - didCompletePlan: bool - hasUnfinishedSubtasks: bool - isApplyDebug: bool - isUserDebug: bool - hasError: bool - -@dataclass -class Subtask: - """Data contract for Subtask.""" - - title: str - description: str - usesFiles: List[str] = field(default_factory=list) - isFinished: bool - -@dataclass -class ConvoMessage: - """Data contract for ConvoMessage.""" - - id: str - userId: str - role: str - tokens: int - num: int - message: str - stopped: bool - flags: ConvoMessageFlags - subtask: Optional[Subtask] = None - addedSubtasks: List[*Subtask] = None - removedSubtasks: List[str] = None - activeContextIds: List[str] = field(default_factory=list) - createdAt: Time - -@dataclass -class ConvoSummary: - """Data contract for ConvoSummary.""" - - id: str - latestConvoMessageCreatedAt: Time - lastestConvoMessageId: str - summary: str - tokens: int - numMessages: int - createdAt: Time - -@dataclass -class Operation: - """Data contract for Operation.""" - - type_: OperationType - path: str - destination: str - content: str - description: str - replybefore: str - numtokens: int - -@dataclass -class ConvoMessageDescription: - """Data contract for ConvoMessageDescription.""" - - id: str - convoMessageId: str - summarizedToMessageId: str - wroteFiles: bool - # Files []string - commitMsg: str - operations: List[*Operation] = field(default_factory=list) - didBuild: bool - buildPathsInvalidated: Dict[str, map[string]bool] = field(default_factory=dict) - error: str - appliedAt: Optional[Time] = None - createdAt: Time - updatedAt: Time - -@dataclass -class PlanBuild: - """Data contract for PlanBuild.""" - - id: str - convoMessageId: str - filePath: str - error: str - createdAt: Time - updatedAt: Time - -@dataclass -class Replacement: - """Data contract for Replacement.""" - - id: str - old: str - summary: str - entireFile: bool - new: str - failed: bool - rejectedAt: Optional[Time] = None - streamedChange: Optional[StreamedChangeWithLineNums] = None - -@dataclass -class PlanFileResult: - """Data contract for PlanFileResult.""" - - id: str - typeVersion: int - replaceWithLineNums: bool - convoMessageId: str - planBuildId: str - path: str - content: str - anyFailed: bool - appliedAt: Optional[Time] = None - rejectedAt: Optional[Time] = None - replacements: List[*Replacement] = field(default_factory=list) - removedFile: bool - createdAt: Time - updatedAt: Time - -@dataclass -class CurrentPlanFiles: - """Data contract for CurrentPlanFiles.""" - - files: Dict[str, map[string]string] = field(default_factory=dict) - removedByPath: Dict[str, map[string]bool] = field(default_factory=dict) - updatedAtByPath: Dict[str, Time] = field(default_factory=dict) - -@dataclass -class PlanResult: - """Data contract for PlanResult.""" - - sortedPaths: List[str] = field(default_factory=list) - fileResultsByPath: PlanFileResultsByPath - results: List[*PlanFileResult] = field(default_factory=list) - replacementsByPath: Dict[str, map[string][]*Replacement] = field(default_factory=dict) - -@dataclass -class PlanApply: - """Data contract for PlanApply.""" - - id: str - userId: str - convoMessageIds: List[str] = field(default_factory=list) - convoMessageDescriptionIds: List[str] = field(default_factory=list) - planFileResultIds: List[str] = field(default_factory=list) - commitMsg: str - createdAt: Time - -@dataclass -class CurrentPlanState: - """Data contract for CurrentPlanState.""" - - planResult: Optional[PlanResult] = None - currentPlanFiles: Optional[CurrentPlanFiles] = None - convoMessageDescriptions: List[*ConvoMessageDescription] = field(default_factory=list) - planApplies: List[*PlanApply] = field(default_factory=list) - contextsByPath: Dict[str, map[string]*Context] = field(default_factory=dict) - -@dataclass -class OrgRole: - """Data contract for OrgRole.""" - - id: str - isDefault: bool - label: str - description: str - -@dataclass -class CloudBillingFields: - """Data contract for CloudBillingFields.""" - - creditsBalance: Decimal - monthlyGrant: Decimal - autoRebuyEnabled: bool - autoRebuyMinThreshold: Decimal - autoRebuyToBalance: Decimal - notifyThreshold: Decimal - maxThresholdPerMonth: Decimal - billingCycleStartedAt: Time - changedBillingMode: bool - trialPaid: bool - stripeSubscriptionId: Optional[str] = None - subscriptionStatus: Optional[str] = None - subscriptionPausedAt: Optional[Time] = None - stripePaymentMethod: Optional[str] = None - # for 3ds/sca approvals - subscriptionActionRequired: bool - subscriptionActionRequiredInvoiceUrl: Optional[str] = None - -@dataclass -class CreditsTransaction: - """Data contract for CreditsTransaction.""" - - id: str - orgId: str - orgName: str - userId: Optional[str] = None - userEmail: Optional[str] = None - userName: Optional[str] = None - transactionType: CreditsTransactionType - amount: Decimal - startBalance: Decimal - endBalance: Decimal - creditType: Optional[CreditType] = None - creditIsAutoRebuy: bool - creditAutoRebuyMinThreshold: Optional[Decimal] = None - creditAutoRebuyToBalance: Optional[Decimal] = None - debitInputTokens: Optional[int] = None - debitOutputTokens: Optional[int] = None - debitModelInputPricePerToken: Optional[Decimal] = None - debitModelOutputPricePerToken: Optional[Decimal] = None - debitBaseAmount: Optional[Decimal] = None - debitSurcharge: Optional[Decimal] = None - debitModelProvider: Optional[ModelProvider] = None - debitModelName: Optional[str] = None - debitModelPackName: Optional[str] = None - debitModelRole: Optional[ModelRole] = None - debitPurpose: Optional[str] = None - debitPlanId: Optional[str] = None - debitPlanName: Optional[str] = None - debitId: Optional[str] = None - debitCacheDiscount: Optional[Decimal] = None - debitSessionId: Optional[str] = None - createdAt: Time diff --git a/docs/reference/contracts/stubs/org_user_config.py b/docs/reference/contracts/stubs/org_user_config.py deleted file mode 100644 index 6e7769c89..000000000 --- a/docs/reference/contracts/stubs/org_user_config.py +++ /dev/null @@ -1,15 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -@dataclass -class OrgUserConfig: - """Data contract for OrgUserConfig.""" - - promptedClaudeMax: bool - useClaudeSubscription: bool - claudeSubscriptionCooldownStartedAt: Time diff --git a/docs/reference/contracts/stubs/plan_config.py b/docs/reference/contracts/stubs/plan_config.py deleted file mode 100644 index 559660a57..000000000 --- a/docs/reference/contracts/stubs/plan_config.py +++ /dev/null @@ -1,64 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class string(str, Enum): - """Enum for string.""" - - EditorTypeVim = "EditorTypeVim" - EditorTypeNano = "EditorTypeNano" - - -class AutoModeType(str, Enum): - """Enum for AutoModeType.""" - - AutoModeFull = "AutoModeFull" - AutoModeSemi = "AutoModeSemi" - AutoModePlus = "AutoModePlus" - AutoModeBasic = "AutoModeBasic" - AutoModeNone = "AutoModeNone" - AutoModeCustom = "AutoModeCustom" - - -AutoModeType = str - -@dataclass -class PlanConfig: - """Data contract for PlanConfig.""" - - # QuietMode bool - autoMode: AutoModeType - editor: str - editorCommand: str - editorArgs: List[str] = field(default_factory=list) - editorOpenManually: bool - autoContinue: bool - autoBuild: bool - autoUpdateContext: bool - autoContext: bool - # AutoApproveContext bool - smartContext: bool - autoApply: bool - autoCommit: bool - skipCommit: bool - canExec: bool - autoExec: bool - autoDebug: bool - autoDebugTries: int - autoRevertOnRewind: bool - # ReplMode bool - skipChangesMenu: bool - -@dataclass -class ConfigSetting: - """Data contract for ConfigSetting.""" - - name: str - desc: str - choices: Optional[List[str]] = None - hascustomchoice: bool - sortkey: str diff --git a/docs/reference/contracts/stubs/plan_model_settings.py b/docs/reference/contracts/stubs/plan_model_settings.py deleted file mode 100644 index a866a89ae..000000000 --- a/docs/reference/contracts/stubs/plan_model_settings.py +++ /dev/null @@ -1,22 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -@dataclass -class PlanSettings: - """Data contract for PlanSettings.""" - - modelPackName: str - modelPack: Optional[ModelPack] = None - customModelPacks: List[*ModelPack] = field(default_factory=list) - customModels: List[*CustomModel] = field(default_factory=list) - customModelsById: Dict[str, map[ModelId]*CustomModel] = field(default_factory=dict) - customProviders: List[*CustomProvider] = field(default_factory=list) - usesCustomProviderByModelId: Dict[str, map[ModelId][]BaseModelUsesProvider] = field(default_factory=dict) - isCloud: bool - configured: bool - updatedAt: Time diff --git a/docs/reference/contracts/stubs/plan_status.py b/docs/reference/contracts/stubs/plan_status.py deleted file mode 100644 index 084096b94..000000000 --- a/docs/reference/contracts/stubs/plan_status.py +++ /dev/null @@ -1,22 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class PlanStatus(str, Enum): - """Enum for PlanStatus.""" - - PlanStatusDraft = "PlanStatusDraft" - PlanStatusReplying = "PlanStatusReplying" - PlanStatusDescribing = "PlanStatusDescribing" - PlanStatusBuilding = "PlanStatusBuilding" - PlanStatusMissingFile = "PlanStatusMissingFile" - PlanStatusFinished = "PlanStatusFinished" - PlanStatusStopped = "PlanStatusStopped" - PlanStatusError = "PlanStatusError" - - -PlanStatus = str diff --git a/docs/reference/contracts/stubs/rbac.py b/docs/reference/contracts/stubs/rbac.py deleted file mode 100644 index 644232c25..000000000 --- a/docs/reference/contracts/stubs/rbac.py +++ /dev/null @@ -1,32 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class Permission(str, Enum): - """Enum for Permission.""" - - PermissionDeleteOrg = "PermissionDeleteOrg" - PermissionManageEmailDomainAuth = "PermissionManageEmailDomainAuth" - PermissionManageBilling = "PermissionManageBilling" - PermissionInviteUser = "PermissionInviteUser" - PermissionRemoveUser = "PermissionRemoveUser" - PermissionSetUserRole = "PermissionSetUserRole" - PermissionListOrgRoles = "PermissionListOrgRoles" - PermissionCreateProject = "PermissionCreateProject" - PermissionRenameAnyProject = "PermissionRenameAnyProject" - PermissionDeleteAnyProject = "PermissionDeleteAnyProject" - PermissionCreatePlan = "PermissionCreatePlan" - PermissionManageAnyPlanShares = "PermissionManageAnyPlanShares" - PermissionRenameAnyPlan = "PermissionRenameAnyPlan" - PermissionDeleteAnyPlan = "PermissionDeleteAnyPlan" - PermissionUpdateAnyPlan = "PermissionUpdateAnyPlan" - PermissionArchiveAnyPlan = "PermissionArchiveAnyPlan" - - -Permission = str - -Permissions = map[string]bool diff --git a/docs/reference/contracts/stubs/req_res.py b/docs/reference/contracts/stubs/req_res.py deleted file mode 100644 index 88c9125c3..000000000 --- a/docs/reference/contracts/stubs/req_res.py +++ /dev/null @@ -1,467 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class BuildMode(str, Enum): - """Enum for BuildMode.""" - - BuildModeAuto = "BuildModeAuto" - BuildModeNone = "BuildModeNone" - - -class RespondMissingFileChoice(str, Enum): - """Enum for RespondMissingFileChoice.""" - - RespondMissingFileChoiceLoad = "RespondMissingFileChoiceLoad" - RespondMissingFileChoiceSkip = "RespondMissingFileChoiceSkip" - RespondMissingFileChoiceOverwrite = "RespondMissingFileChoiceOverwrite" - - -BuildMode = str - -RespondMissingFileChoice = str - -FileMapInputs = map[string]string - -LoadContextRequest = []*LoadContextParams - -UpdateContextRequest = map[string]*UpdateContextParams - -UpdateContextResponse = = - -@dataclass -class CreateEmailVerificationRequest: - """Data contract for CreateEmailVerificationRequest.""" - - email: str - userId: str - requireUser: bool - requireNoUser: bool - -@dataclass -class CreateEmailVerificationResponse: - """Data contract for CreateEmailVerificationResponse.""" - - hasAccount: bool - isLocalMode: bool - -@dataclass -class VerifyEmailPinRequest: - """Data contract for VerifyEmailPinRequest.""" - - email: str - pin: str - -@dataclass -class SignInRequest: - """Data contract for SignInRequest.""" - - email: str - pin: str - isSignInCode: bool - -@dataclass -class UiSignInToken: - """Data contract for UiSignInToken.""" - - pin: str - redirectTo: str - -@dataclass -class CreateAccountRequest: - """Data contract for CreateAccountRequest.""" - - email: str - pin: str - userName: str - -@dataclass -class SessionResponse: - """Data contract for SessionResponse.""" - - userId: str - token: str - email: str - userName: str - orgs: List[*Org] = field(default_factory=list) - isLocalMode: bool - -@dataclass -class CreateOrgRequest: - """Data contract for CreateOrgRequest.""" - - name: str - autoAddDomainUsers: bool - -@dataclass -class ConvertTrialRequest: - """Data contract for ConvertTrialRequest.""" - - email: str - pin: str - userName: str - orgName: str - orgAutoAddDomainUsers: bool - -@dataclass -class CreateOrgResponse: - """Data contract for CreateOrgResponse.""" - - id: str - -@dataclass -class InviteRequest: - """Data contract for InviteRequest.""" - - email: str - name: str - orgRoleId: str - -@dataclass -class CreateProjectRequest: - """Data contract for CreateProjectRequest.""" - - name: str - -@dataclass -class CreateProjectResponse: - """Data contract for CreateProjectResponse.""" - - id: str - -@dataclass -class SetProjectPlanRequest: - """Data contract for SetProjectPlanRequest.""" - - planId: str - -@dataclass -class RenameProjectRequest: - """Data contract for RenameProjectRequest.""" - - name: str - -@dataclass -class CreatePlanRequest: - """Data contract for CreatePlanRequest.""" - - name: str - -@dataclass -class CreatePlanResponse: - """Data contract for CreatePlanResponse.""" - - id: str - name: str - -@dataclass -class GetCurrentBranchByPlanIdRequest: - """Data contract for GetCurrentBranchByPlanIdRequest.""" - - currentBranchByPlanId: Dict[str, map[string]string] = field(default_factory=dict) - -@dataclass -class ListPlansRunningResponse: - """Data contract for ListPlansRunningResponse.""" - - branches: List[*Branch] = field(default_factory=list) - streamStartedAtByBranchId: Dict[str, Time] = field(default_factory=dict) - streamFinishedAtByBranchId: Dict[str, Time] = field(default_factory=dict) - streamIdByBranchId: Dict[str, map[string]string] = field(default_factory=dict) - plansById: Dict[str, map[string]*Plan] = field(default_factory=dict) - -@dataclass -class TellPlanRequest: - """Data contract for TellPlanRequest.""" - - prompt: str - buildMode: BuildMode - connectStream: bool - autoContinue: bool - isUserContinue: bool - isUserDebug: bool - isApplyDebug: bool - isChatOnly: bool - autoContext: bool - smartContext: bool - execEnabled: bool - osDetails: str - # deprecated - apiKeys: Dict[str, map[string]string] = field(default_factory=dict) - # deprecated - openAIOrgId: str - authVars: Dict[str, map[string]string] = field(default_factory=dict) - projectPaths: Dict[str, map[string]bool] = field(default_factory=dict) - isImplementationOfChat: bool - isGitRepo: bool - sessionId: str - -@dataclass -class BuildPlanRequest: - """Data contract for BuildPlanRequest.""" - - connectStream: bool - # deprecated - apiKeys: Dict[str, map[string]string] = field(default_factory=dict) - # deprecated - openAIOrgId: str - authVars: Dict[str, map[string]string] = field(default_factory=dict) - projectPaths: Dict[str, map[string]bool] = field(default_factory=dict) - sessionId: str - -@dataclass -class RespondMissingFileRequest: - """Data contract for RespondMissingFileRequest.""" - - choice: RespondMissingFileChoice - filePath: str - body: str - -@dataclass -class LoadContextParams: - """Data contract for LoadContextParams.""" - - contextType: ContextType - name: str - url: str - file_path: str - body: str - forceSkipIgnore: bool - imageDetail: ImageURLDetail - autoLoaded: bool - inputShas: Dict[str, map[string]string] = field(default_factory=dict) - inputTokens: Dict[str, map[string]int] = field(default_factory=dict) - inputSizes: Dict[str, map[string]int64] = field(default_factory=dict) - # For naming piped data - mapBodies: FileMapBodies - # deprecated - apiKeys: Dict[str, map[string]string] = field(default_factory=dict) - # deprecated - openAIBase: str - # deprecated - openAIOrgId: str - authVars: Dict[str, map[string]string] = field(default_factory=dict) - sessionId: str - -@dataclass -class LoadContextResponse: - """Data contract for LoadContextResponse.""" - - tokensAdded: int - totalTokens: int - maxTokensExceeded: bool - maxTokens: int - msg: str - -@dataclass -class UpdateContextParams: - """Data contract for UpdateContextParams.""" - - body: str - inputShas: Dict[str, map[string]string] = field(default_factory=dict) - inputTokens: Dict[str, map[string]int] = field(default_factory=dict) - inputSizes: Dict[str, map[string]int64] = field(default_factory=dict) - mapBodies: FileMapBodies - removedMapPaths: List[str] = field(default_factory=list) - -@dataclass -class GetFileMapRequest: - """Data contract for GetFileMapRequest.""" - - mapInputs: FileMapInputs - -@dataclass -class GetFileMapResponse: - """Data contract for GetFileMapResponse.""" - - mapBodies: FileMapBodies - -@dataclass -class LoadCachedFileMapRequest: - """Data contract for LoadCachedFileMapRequest.""" - - filePaths: List[str] = field(default_factory=list) - -@dataclass -class LoadCachedFileMapResponse: - """Data contract for LoadCachedFileMapResponse.""" - - loadRes: Optional[LoadContextResponse] = None - cachedByPath: Dict[str, map[string]bool] = field(default_factory=dict) - -@dataclass -class GetContextBodyRequest: - """Data contract for GetContextBodyRequest.""" - - contextId: str - -@dataclass -class GetContextBodyResponse: - """Data contract for GetContextBodyResponse.""" - - body: str - -@dataclass -class DeleteContextRequest: - """Data contract for DeleteContextRequest.""" - - ids: Dict[str, map[string]bool] = field(default_factory=dict) - -@dataclass -class DeleteContextResponse: - """Data contract for DeleteContextResponse.""" - - tokensRemoved: int - totalTokens: int - msg: str - -@dataclass -class RejectFileRequest: - """Data contract for RejectFileRequest.""" - - filePath: str - -@dataclass -class RejectFilesRequest: - """Data contract for RejectFilesRequest.""" - - paths: List[str] = field(default_factory=list) - -@dataclass -class RewindPlanRequest: - """Data contract for RewindPlanRequest.""" - - sha: str - -@dataclass -class RewindPlanResponse: - """Data contract for RewindPlanResponse.""" - - latestSha: str - latestCommit: str - -@dataclass -class LogResponse: - """Data contract for LogResponse.""" - - shas: List[str] = field(default_factory=list) - body: str - -@dataclass -class CreateBranchRequest: - """Data contract for CreateBranchRequest.""" - - name: str - -@dataclass -class UpdateSettingsRequest: - """Data contract for UpdateSettingsRequest.""" - - modelPackName: str - modelPack: Optional[ModelPack] = None - -@dataclass -class UpdateSettingsResponse: - """Data contract for UpdateSettingsResponse.""" - - msg: str - -@dataclass -class UpdatePlanConfigRequest: - """Data contract for UpdatePlanConfigRequest.""" - - config: Optional[PlanConfig] = None - -@dataclass -class UpdateDefaultPlanConfigRequest: - """Data contract for UpdateDefaultPlanConfigRequest.""" - - config: Optional[PlanConfig] = None - -@dataclass -class GetPlanConfigResponse: - """Data contract for GetPlanConfigResponse.""" - - config: Optional[PlanConfig] = None - -@dataclass -class GetDefaultPlanConfigResponse: - """Data contract for GetDefaultPlanConfigResponse.""" - - config: Optional[PlanConfig] = None - -@dataclass -class ListUsersResponse: - """Data contract for ListUsersResponse.""" - - users: List[*User] = field(default_factory=list) - orgUsersByUserId: Dict[str, map[string]*OrgUser] = field(default_factory=dict) - -@dataclass -class ApplyPlanRequest: - """Data contract for ApplyPlanRequest.""" - - # deprecated - apiKeys: Dict[str, map[string]string] = field(default_factory=dict) - # deprecated - openAIBase: str - # deprecated - openAIOrgId: str - authVars: Dict[str, map[string]string] = field(default_factory=dict) - sessionId: str - -@dataclass -class RenamePlanRequest: - """Data contract for RenamePlanRequest.""" - - name: str - -@dataclass -class GetBuildStatusResponse: - """Data contract for GetBuildStatusResponse.""" - - builtFiles: Dict[str, map[string]bool] = field(default_factory=dict) - isBuildingByPath: Dict[str, map[string]bool] = field(default_factory=dict) - -@dataclass -class CreditsLogRequest: - """Data contract for CreditsLogRequest.""" - - transactionType: CreditsTransactionType - planId: str - sessionId: str - dayStart: Optional[Time] = None - month: bool - -@dataclass -class CreditsLogResponse: - """Data contract for CreditsLogResponse.""" - - transactions: List[*CreditsTransaction] = field(default_factory=list) - numPages: int - numPagesMax: bool - monthStart: Time - planNamesById: Dict[str, map[string]string] = field(default_factory=dict) - -@dataclass -class CreditsSummaryResponse: - """Data contract for CreditsSummaryResponse.""" - - balance: Decimal - totalSpend: Decimal - monthStart: Time - byPlanId: Dict[str, Decimal] = field(default_factory=dict) - planNamesById: Dict[str, map[string]string] = field(default_factory=dict) - byModelName: Dict[str, Decimal] = field(default_factory=dict) - byPurpose: Dict[str, Decimal] = field(default_factory=dict) - cacheSavings: Decimal - -@dataclass -class GetBalanceResponse: - """Data contract for GetBalanceResponse.""" - - balance: Decimal diff --git a/docs/reference/contracts/stubs/stream.py b/docs/reference/contracts/stubs/stream.py deleted file mode 100644 index ee9aaaf81..000000000 --- a/docs/reference/contracts/stubs/stream.py +++ /dev/null @@ -1,54 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class StreamMessageType(str, Enum): - """Enum for StreamMessageType.""" - - StreamMessageStart = "StreamMessageStart" - StreamMessageConnectActive = "StreamMessageConnectActive" - StreamMessageHeartbeat = "StreamMessageHeartbeat" - StreamMessageReply = "StreamMessageReply" - StreamMessageDescribing = "StreamMessageDescribing" - StreamMessageRepliesFinished = "StreamMessageRepliesFinished" - StreamMessageBuildInfo = "StreamMessageBuildInfo" - StreamMessagePromptMissingFile = "StreamMessagePromptMissingFile" - StreamMessageLoadContext = "StreamMessageLoadContext" - StreamMessageAborted = "StreamMessageAborted" - StreamMessageFinished = "StreamMessageFinished" - StreamMessageError = "StreamMessageError" - StreamMessageMulti = "StreamMessageMulti" - - -StreamMessageType = str - -@dataclass -class BuildInfo: - """Data contract for BuildInfo.""" - - path: str - numTokens: int - finished: bool - removed: bool = None - -@dataclass -class StreamMessage: - """Data contract for StreamMessage.""" - - type_: StreamMessageType - replyChunk: str = None - buildInfo: Optional[BuildInfo] = None - description: Optional[ConvoMessageDescription] = None - error: Optional[ApiError] = None - missingFilePath: str = None - missingFileAutoContext: bool = None - modelStreamId: str = None - loadContextFiles: List[str] = None - initPrompt: str = None - initReplies: List[str] = None - initBuildOnly: bool = None - streamMessages: List[StreamMessage] = None diff --git a/docs/reference/contracts/stubs/streamed_change.py b/docs/reference/contracts/stubs/streamed_change.py deleted file mode 100644 index 775047851..000000000 --- a/docs/reference/contracts/stubs/streamed_change.py +++ /dev/null @@ -1,25 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -@dataclass -class StreamedChangeSection: - """Data contract for StreamedChangeSection.""" - - startLine: int - endLine: int - startLineString: str - endLineString: str - -@dataclass -class StreamedChangeWithLineNums: - """Data contract for StreamedChangeWithLineNums.""" - - old: StreamedChangeSection - startLineIncluded: bool - endLineIncluded: bool - new: str diff --git a/docs/reference/contracts/stubs/syntax.py b/docs/reference/contracts/stubs/syntax.py deleted file mode 100644 index 325e5ba9f..000000000 --- a/docs/reference/contracts/stubs/syntax.py +++ /dev/null @@ -1,47 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -class Language(str, Enum): - """Enum for Language.""" - - LanguageBash = "LanguageBash" - LanguageC = "LanguageC" - LanguageCpp = "LanguageCpp" - LanguageCsharp = "LanguageCsharp" - LanguageCss = "LanguageCss" - LanguageCue = "LanguageCue" - LanguageDockerfile = "LanguageDockerfile" - LanguageElixir = "LanguageElixir" - LanguageElm = "LanguageElm" - LanguageGo = "LanguageGo" - LanguageGroovy = "LanguageGroovy" - LanguageHcl = "LanguageHcl" - LanguageHtml = "LanguageHtml" - LanguageJava = "LanguageJava" - LanguageJavascript = "LanguageJavascript" - LanguageJson = "LanguageJson" - LanguageKotlin = "LanguageKotlin" - LanguageLua = "LanguageLua" - LanguageOCaml = "LanguageOCaml" - LanguagePhp = "LanguagePhp" - LanguageProtobuf = "LanguageProtobuf" - LanguagePython = "LanguagePython" - LanguageRuby = "LanguageRuby" - LanguageRust = "LanguageRust" - LanguageScala = "LanguageScala" - LanguageSvelte = "LanguageSvelte" - LanguageSwift = "LanguageSwift" - LanguageToml = "LanguageToml" - LanguageTypescript = "LanguageTypescript" - LanguageJsx = "LanguageJsx" - LanguageTsx = "LanguageTsx" - LanguageYaml = "LanguageYaml" - LanguageMarkdown = "LanguageMarkdown" - - -Language = str diff --git a/docs/reference/contracts/stubs/utils.py b/docs/reference/contracts/stubs/utils.py deleted file mode 100644 index 54622029f..000000000 --- a/docs/reference/contracts/stubs/utils.py +++ /dev/null @@ -1,9 +0,0 @@ -"""Auto-generated Python stubs from Go contracts.""" - -from dataclasses import dataclass, field -from typing import Any, Dict, List, Optional -from datetime import datetime -from enum import Enum - - -LineNumberedTextType = str diff --git a/docs/reference/env_mapping.txt b/docs/reference/env_mapping.txt deleted file mode 100644 index 8676d2f85..000000000 --- a/docs/reference/env_mapping.txt +++ /dev/null @@ -1,51 +0,0 @@ -# Environment Variable Mapping -# Old Name -> New Name -#================================================== - -PLANDEX_ENV -> CLEVERAGENTS_ENV -PLANDEX_API_HOST -> CLEVERAGENTS_API_HOST -PLANDEX_AWS_PROFILE -> CLEVERAGENTS_AWS_PROFILE -PLANDEX_SKIP_UPGRADE -> CLEVERAGENTS_SKIP_UPGRADE -PLANDEX_OUT_DIR -> CLEVERAGENTS_OUT_DIR -PLANDEX_DEV_CLI_OUT_DIR -> CLEVERAGENTS_DEV_CLI_OUT_DIR -PLANDEX_DEV_CLI_NAME -> CLEVERAGENTS_DEV_CLI_NAME -PLANDEX_DEV_CLI_ALIAS -> CLEVERAGENTS_DEV_CLI_ALIAS -GOPATH -> CLEVERAGENTS_GOPATH -GOENV -> CLEVERAGENTS_GOENV -PLANDEX_BASE_DIR -> CLEVERAGENTS_BASE_DIR -API_HOST -> CLEVERAGENTS_API_HOST -PORT -> CLEVERAGENTS_PORT -DATABASE_URL -> CLEVERAGENTS_DATABASE_URL -LOCAL_MODE -> CLEVERAGENTS_LOCAL_MODE -OLLAMA_BASE_URL -> CLEVERAGENTS_OLLAMA_BASE_URL -SMTP_HOST -> CLEVERAGENTS_SMTP_HOST -SMTP_PORT -> CLEVERAGENTS_SMTP_PORT -SMTP_USER -> CLEVERAGENTS_SMTP_USER -SMTP_PASSWORD -> CLEVERAGENTS_SMTP_PASSWORD -DB_HOST -> CLEVERAGENTS_DB_HOST -DB_PORT -> CLEVERAGENTS_DB_PORT -DB_USER -> CLEVERAGENTS_DB_USER -DB_PASSWORD -> CLEVERAGENTS_DB_PASSWORD -DB_NAME -> CLEVERAGENTS_DB_NAME -MIGRATIONS_DIR -> CLEVERAGENTS_MIGRATIONS_DIR -PLANDEX_CLOUD -> CLEVERAGENTS_CLOUD -SMTP_FROM -> CLEVERAGENTS_SMTP_FROM -IS_CLOUD -> CLEVERAGENTS_IS_CLOUD -APP_SUBDOMAIN -> CLEVERAGENTS_APP_SUBDOMAIN -IP -> CLEVERAGENTS_IP -ECS_CONTAINER_METADATA_URI -> CLEVERAGENTS_ECS_CONTAINER_METADATA_URI -LITELLM_PROXY_DIR -> CLEVERAGENTS_LITELLM_PROXY_DIR -PATH -> CLEVERAGENTS_PATH -HOME -> CLEVERAGENTS_HOME -VERBOSE_LOGGING -> CLEVERAGENTS_VERBOSE_LOGGING -PLANDEX_REPL_SESSION_ID -> CLEVERAGENTS_REPL_SESSION_ID -EDITOR -> CLEVERAGENTS_EDITOR -VISUAL -> CLEVERAGENTS_VISUAL -PLANDEX_REPL -> CLEVERAGENTS_REPL -PLANDEX_REPL_OUTPUT_FILE -> CLEVERAGENTS_REPL_OUTPUT_FILE -GLAMOUR_STYLE -> CLEVERAGENTS_GLAMOUR_STYLE -PLANDEX_DISABLE_SUGGESTIONS -> CLEVERAGENTS_DISABLE_SUGGESTIONS -SHELL -> CLEVERAGENTS_SHELL -PLANDEX_COLUMNS -> CLEVERAGENTS_COLUMNS -COLUMNS -> CLEVERAGENTS_COLUMNS -PLANDEX_STREAM_FOREGROUND_COLOR -> CLEVERAGENTS_STREAM_FOREGROUND_COLOR diff --git a/docs/reference/env_migration_guide.md b/docs/reference/env_migration_guide.md deleted file mode 100644 index 027fee4ad..000000000 --- a/docs/reference/env_migration_guide.md +++ /dev/null @@ -1,158 +0,0 @@ -# Environment Variable Migration Guide - -## Overview - -Total variables: 66 -Variables requiring migration: 16 -Documented variables: 39 -Code-only variables: 27 - -## Variable Mappings - -| Old Name | New Name | Category | Default | Description | -|----------|----------|----------|---------|-------------| -| COLUMNS | CLEVERAGENTS_COLUMNS | CLI | (none) | | -| EDITOR | CLEVERAGENTS_EDITOR | CLI | (none) | | -| GLAMOUR_STYLE | CLEVERAGENTS_GLAMOUR_STYLE | CLI | (none) | | -| PLANDEX_COLUMNS | CLEVERAGENTS_COLUMNS | CLI | (none) | | -| PLANDEX_DISABLE_SUGGESTIONS | CLEVERAGENTS_DISABLE_SUGGESTIONS | CLI | (none) | | -| PLANDEX_REPL | CLEVERAGENTS_REPL | CLI | (none) | | -| PLANDEX_REPL_OUTPUT_FILE | CLEVERAGENTS_REPL_OUTPUT_FILE | CLI | (none) | | -| PLANDEX_REPL_SESSION_ID | CLEVERAGENTS_REPL_SESSION_ID | CLI | (none) | | -| PLANDEX_STREAM_FOREGROUND_COLOR | CLEVERAGENTS_STREAM_FOREGROUND_COLOR | CLI | (none) | | -| SHELL | CLEVERAGENTS_SHELL | CLI | (none) | | -| VISUAL | CLEVERAGENTS_VISUAL | CLI | (none) | | -| GOPATH | CLEVERAGENTS_GOPATH | Development | (none) | This should be already set to your Go folder if yo... | -| PLANDEX_DEV_CLI_ALIAS | CLEVERAGENTS_DEV_CLI_ALIAS | Development | pdxd | The alias for the development binary when using de... | -| PLANDEX_DEV_CLI_NAME | CLEVERAGENTS_DEV_CLI_NAME | Development | plandex-dev | The name of the development binary when using dev.... | -| PLANDEX_DEV_CLI_OUT_DIR | CLEVERAGENTS_DEV_CLI_OUT_DIR | Development | /usr/local/bin | Where the development binary should be output when... | -| PLANDEX_OUT_DIR | CLEVERAGENTS_OUT_DIR | Development | /usr/local/bin | Where the development binary should be output when... | -| API_HOST | CLEVERAGENTS_API_HOST | General | (none) | The host the API server listens on. Defaults to 'h... | -| DATABASE_URL | CLEVERAGENTS_DATABASE_URL | General | (none) | The URL of the PostgreSQL database. Defaults to 'p... | -| GOENV | CLEVERAGENTS_GOENV | General | development | Whether to run in development or production mode. ... | -| LOCAL_MODE | CLEVERAGENTS_LOCAL_MODE | General | (none) | Whether to run in local mode | -| OLLAMA_BASE_URL | CLEVERAGENTS_OLLAMA_BASE_URL | General | (none) | The base URL of the Ollama server—only need when t... | -| PLANDEX_API_HOST | CLEVERAGENTS_API_HOST | General | (none) | Defaults to 'http://localhost:8099' if PLANDEX_ENV... | -| PLANDEX_BASE_DIR | CLEVERAGENTS_BASE_DIR | General | (none) | The base directory to read and write files. Defaul... | -| PLANDEX_ENV | CLEVERAGENTS_ENV | General | development | Set this to 'development' to default to the local ... | -| PORT | CLEVERAGENTS_PORT | General | 8099 | The port the server listens on. Defaults to 8099. | -| ANTHROPIC_API_KEY | ANTHROPIC_API_KEY | LLM Providers | (none) | Your Anthropic API key | -| AWS_ACCESS_KEY_ID | AWS_ACCESS_KEY_ID | LLM Providers | (none) | Your AWS access key ID | -| AWS_INFERENCE_PROFILE_ARN | AWS_INFERENCE_PROFILE_ARN | LLM Providers | (none) | Your AWS inference profile ARN | -| AWS_REGION | AWS_REGION | LLM Providers | (none) | Your AWS region | -| AWS_SECRET_ACCESS_KEY | AWS_SECRET_ACCESS_KEY | LLM Providers | (none) | Your AWS secret access key | -| AWS_SESSION_TOKEN | AWS_SESSION_TOKEN | LLM Providers | (none) | Your AWS session token | -| AZURE_API_BASE | AZURE_API_BASE | LLM Providers | (none) | Your Azure OpenAI API base URL | -| AZURE_API_VERSION | AZURE_API_VERSION | LLM Providers | (none) | Your Azure OpenAI API version | -| AZURE_DEPLOYMENTS_MAP | AZURE_DEPLOYMENTS_MAP | LLM Providers | (none) | Your Azure OpenAI deployments map—a JSON object ma... | -| AZURE_OPENAI_API_KEY | AZURE_OPENAI_API_KEY | LLM Providers | (none) | Your Azure OpenAI API key | -| DEEPSEEK_API_KEY | DEEPSEEK_API_KEY | LLM Providers | (none) | Your DeepSeek API key | -| GEMINI_API_KEY | GEMINI_API_KEY | LLM Providers | (none) | Your Google AI Studio API key | -| GOOGLE_APPLICATION_CREDENTIALS | GOOGLE_APPLICATION_CREDENTIALS | LLM Providers | (none) | Your Google Vertex AI credentials file path | -| OPENAI_API_KEY | OPENAI_API_KEY | LLM Providers | (none) | Your OpenAI key | -| OPENAI_ORG_ID | OPENAI_ORG_ID | LLM Providers | (none) | Your OpenAI organization ID. Defaults to empty. | -| OPENROUTER_API_KEY | OPENROUTER_API_KEY | LLM Providers | (none) | Your OpenRouter.ai API key | -| PERPLEXITY_API_KEY | PERPLEXITY_API_KEY | LLM Providers | (none) | Your Perplexity API key | -| PLANDEX_AWS_PROFILE | CLEVERAGENTS_AWS_PROFILE | LLM Providers | (none) | Name of AWS profile in ~/.aws/credentials to use f... | -| VERTEXAI_LOCATION | VERTEXAI_LOCATION | LLM Providers | (none) | Your Google Vertex AI location | -| VERTEXAI_PROJECT | VERTEXAI_PROJECT | LLM Providers | (none) | Your Google Vertex AI project ID | -| SMTP_HOST | CLEVERAGENTS_SMTP_HOST | SMTP | (none) | Your SMTP host. | -| SMTP_PASSWORD | CLEVERAGENTS_SMTP_PASSWORD | SMTP | (none) | SMTP password. | -| SMTP_PORT | CLEVERAGENTS_SMTP_PORT | SMTP | (none) | Set this to 1025 e.g. if you are using mailhog. | -| SMTP_USER | CLEVERAGENTS_SMTP_USER | SMTP | (none) | SMTP username. | -| APP_SUBDOMAIN | CLEVERAGENTS_APP_SUBDOMAIN | Server | (none) | | -| DB_HOST | CLEVERAGENTS_DB_HOST | Server | (none) | | -| DB_NAME | CLEVERAGENTS_DB_NAME | Server | (none) | | -| DB_PASSWORD | CLEVERAGENTS_DB_PASSWORD | Server | (none) | | -| DB_PORT | CLEVERAGENTS_DB_PORT | Server | (none) | | -| DB_USER | CLEVERAGENTS_DB_USER | Server | (none) | | -| ECS_CONTAINER_METADATA_URI | CLEVERAGENTS_ECS_CONTAINER_METADATA_URI | Server | (none) | | -| HOME | CLEVERAGENTS_HOME | Server | (none) | | -| IP | CLEVERAGENTS_IP | Server | (none) | | -| IS_CLOUD | CLEVERAGENTS_IS_CLOUD | Server | (none) | | -| LITELLM_PROXY_DIR | CLEVERAGENTS_LITELLM_PROXY_DIR | Server | (none) | | -| MIGRATIONS_DIR | CLEVERAGENTS_MIGRATIONS_DIR | Server | (none) | | -| PATH | CLEVERAGENTS_PATH | Server | (none) | | -| PLANDEX_CLOUD | CLEVERAGENTS_CLOUD | Server | (none) | | -| SMTP_FROM | CLEVERAGENTS_SMTP_FROM | Server | (none) | | -| VERBOSE_LOGGING | CLEVERAGENTS_VERBOSE_LOGGING | Server | (none) | | -| PLANDEX_SKIP_UPGRADE | CLEVERAGENTS_SKIP_UPGRADE | Upgrades | (none) | Set this to '1' to skip the auto-upgrade check whe... | - -## Conflicts and Warnings - -- **PLANDEX_ENV**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_ENV - -- **PLANDEX_API_HOST**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_API_HOST - -- **PLANDEX_AWS_PROFILE**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_AWS_PROFILE - -- **PLANDEX_SKIP_UPGRADE**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_SKIP_UPGRADE - -- **PLANDEX_OUT_DIR**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_OUT_DIR - -- **PLANDEX_DEV_CLI_OUT_DIR**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_DEV_CLI_OUT_DIR - -- **PLANDEX_DEV_CLI_OUT_DIR**: Development-specific variable, may need reconsideration - - Type: development_only - - Suggested: CLEVERAGENTS_DEV_CLI_OUT_DIR - -- **PLANDEX_DEV_CLI_NAME**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_DEV_CLI_NAME - -- **PLANDEX_DEV_CLI_NAME**: Development-specific variable, may need reconsideration - - Type: development_only - - Suggested: CLEVERAGENTS_DEV_CLI_NAME - -- **PLANDEX_DEV_CLI_ALIAS**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_DEV_CLI_ALIAS - -- **PLANDEX_DEV_CLI_ALIAS**: Development-specific variable, may need reconsideration - - Type: development_only - - Suggested: CLEVERAGENTS_DEV_CLI_ALIAS - -- **PLANDEX_BASE_DIR**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_BASE_DIR - -- **PLANDEX_CLOUD**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_CLOUD - -- **PLANDEX_REPL_SESSION_ID**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_REPL_SESSION_ID - -- **PLANDEX_REPL**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_REPL - -- **PLANDEX_REPL_OUTPUT_FILE**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_REPL_OUTPUT_FILE - -- **PLANDEX_DISABLE_SUGGESTIONS**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_DISABLE_SUGGESTIONS - -- **PLANDEX_COLUMNS**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_COLUMNS - -- **PLANDEX_STREAM_FOREGROUND_COLOR**: Rename from Plandex to CleverAgents namespace - - Type: migration_required - - Suggested: CLEVERAGENTS_STREAM_FOREGROUND_COLOR - diff --git a/docs/reference/env_variables.json b/docs/reference/env_variables.json deleted file mode 100644 index 9d931c70d..000000000 --- a/docs/reference/env_variables.json +++ /dev/null @@ -1,1082 +0,0 @@ -{ - "variables": { - "COLUMNS": { - "name": "COLUMNS", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/term/utils.go:109" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_COLUMNS" - }, - "EDITOR": { - "name": "EDITOR", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/cmd/plan_exec_helpers.go:41" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_EDITOR" - }, - "GLAMOUR_STYLE": { - "name": "GLAMOUR_STYLE", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/term/format.go:35" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_GLAMOUR_STYLE" - }, - "PLANDEX_COLUMNS": { - "name": "PLANDEX_COLUMNS", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/term/utils.go:88", - "app/cli/term/utils.go:89" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_COLUMNS" - }, - "PLANDEX_DISABLE_SUGGESTIONS": { - "name": "PLANDEX_DISABLE_SUGGESTIONS", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/term/help.go:180" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_DISABLE_SUGGESTIONS" - }, - "PLANDEX_REPL": { - "name": "PLANDEX_REPL", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/stream_tui/run.go:102", - "app/cli/term/repl.go:5" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_REPL" - }, - "PLANDEX_REPL_OUTPUT_FILE": { - "name": "PLANDEX_REPL_OUTPUT_FILE", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/stream_tui/run.go:102", - "app/cli/stream_tui/run.go:104" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_REPL_OUTPUT_FILE" - }, - "PLANDEX_REPL_SESSION_ID": { - "name": "PLANDEX_REPL_SESSION_ID", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/cmd/load.go:58", - "app/cli/cmd/usage.go:73", - "app/cli/cmd/usage.go:82", - "app/cli/cmd/usage.go:240", - "app/cli/cmd/usage.go:259", - "app/cli/plan_exec/tell.go:150" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_REPL_SESSION_ID" - }, - "PLANDEX_STREAM_FOREGROUND_COLOR": { - "name": "PLANDEX_STREAM_FOREGROUND_COLOR", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/term/utils.go:125", - "app/cli/term/utils.go:126" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_STREAM_FOREGROUND_COLOR" - }, - "SHELL": { - "name": "SHELL", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/term/os.go:15" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_SHELL" - }, - "VISUAL": { - "name": "VISUAL", - "default": "", - "description": "", - "category": "CLI", - "sources": [ - "code" - ], - "usage_locations": [ - "app/cli/cmd/plan_exec_helpers.go:43" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_VISUAL" - }, - "GOPATH": { - "name": "GOPATH", - "default": "", - "description": "This should be already set to your Go folder if you've installed Golang.", - "category": "Development", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "CLEVERAGENTS_GOPATH" - }, - "PLANDEX_DEV_CLI_ALIAS": { - "name": "PLANDEX_DEV_CLI_ALIAS", - "default": "pdxd", - "description": "The alias for the development binary when using dev.sh", - "category": "Development", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "CLEVERAGENTS_DEV_CLI_ALIAS" - }, - "PLANDEX_DEV_CLI_NAME": { - "name": "PLANDEX_DEV_CLI_NAME", - "default": "plandex-dev", - "description": "The name of the development binary when using dev.sh", - "category": "Development", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "CLEVERAGENTS_DEV_CLI_NAME" - }, - "PLANDEX_DEV_CLI_OUT_DIR": { - "name": "PLANDEX_DEV_CLI_OUT_DIR", - "default": "/usr/local/bin", - "description": "Where the development binary should be output when using dev.sh", - "category": "Development", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "CLEVERAGENTS_DEV_CLI_OUT_DIR" - }, - "PLANDEX_OUT_DIR": { - "name": "PLANDEX_OUT_DIR", - "default": "/usr/local/bin", - "description": "Where the development binary should be output when using dev.sh", - "category": "Development", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "CLEVERAGENTS_OUT_DIR" - }, - "API_HOST": { - "name": "API_HOST", - "default": "", - "description": "The host the API server listens on. Defaults to 'http://localhost:$PORT'. In production mode, should be a host like 'https://api.your-domain.ai'.", - "category": "General", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "CLEVERAGENTS_API_HOST" - }, - "DATABASE_URL": { - "name": "DATABASE_URL", - "default": "", - "description": "The URL of the PostgreSQL database. Defaults to 'postgres://plandex:plandex@plandex-postgres:5432/plandex?sslmode=disable' in development mode", - "category": "General", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/db/db.go:27" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_DATABASE_URL" - }, - "GOENV": { - "name": "GOENV", - "default": "development", - "description": "Whether to run in development or production mode. Must be 'development' or 'production'", - "category": "General", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/db/account_helpers.go:17", - "app/server/db/db.go:57", - "app/server/db/db.go:129", - "app/server/db/db.go:137", - "app/server/db/db.go:150", - "app/server/db/fs.go:20", - "app/server/db/fs.go:21", - "app/server/db/fs.go:28", - "app/server/email/invite.go:12", - "app/server/email/verification.go:14", - "app/server/email/verification.go:31", - "app/server/handlers/accounts.go:29", - "app/server/handlers/accounts.go:123", - "app/server/handlers/auth_helpers.go:98", - "app/server/handlers/auth_helpers.go:108", - "app/server/handlers/auth_helpers.go:145", - "app/server/handlers/auth_helpers.go:152", - "app/server/handlers/auth_helpers.go:201", - "app/server/handlers/auth_helpers.go:209", - "app/server/handlers/auth_helpers.go:260", - "app/server/handlers/auth_helpers.go:300", - "app/server/handlers/auth_helpers.go:436", - "app/server/handlers/invites.go:22", - "app/server/handlers/invites.go:165", - "app/server/handlers/invites.go:223", - "app/server/handlers/invites.go:281", - "app/server/handlers/invites.go:339", - "app/server/handlers/sessions.go:85", - "app/server/handlers/users.go:21", - "app/server/handlers/users.go:96", - "app/server/host/ip.go:16", - "app/server/model/client.go:538", - "app/server/setup/setup.go:67" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_GOENV" - }, - "LOCAL_MODE": { - "name": "LOCAL_MODE", - "default": "", - "description": "Whether to run in local mode", - "category": "General", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/db/account_helpers.go:17", - "app/server/db/fs.go:21", - "app/server/handlers/accounts.go:29", - "app/server/handlers/accounts.go:123", - "app/server/handlers/auth_helpers.go:300", - "app/server/handlers/auth_helpers.go:436", - "app/server/handlers/invites.go:22", - "app/server/handlers/invites.go:165", - "app/server/handlers/invites.go:223", - "app/server/handlers/invites.go:281", - "app/server/handlers/invites.go:339", - "app/server/handlers/sessions.go:85", - "app/server/handlers/users.go:21", - "app/server/handlers/users.go:96" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_LOCAL_MODE" - }, - "OLLAMA_BASE_URL": { - "name": "OLLAMA_BASE_URL", - "default": "", - "description": "The base URL of the Ollama server\u2014only need when the server is running in a Docker container and needs to access Ollama models running outside of the container", - "category": "General", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/model/client.go:295", - "app/server/model/client.go:296", - "app/server/model/litellm.go:125", - "app/server/model/litellm.go:128" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_OLLAMA_BASE_URL" - }, - "PLANDEX_API_HOST": { - "name": "PLANDEX_API_HOST", - "default": "", - "description": "Defaults to 'http://localhost:8099' if PLANDEX_ENV is development, otherwise it's 'https://api.plandex.ai'\u2014override this to use a different host.", - "category": "General", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/cli/api/clients.go:25" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_API_HOST" - }, - "PLANDEX_BASE_DIR": { - "name": "PLANDEX_BASE_DIR", - "default": "", - "description": "The base directory to read and write files. Defaults to '$HOME/plandex-server' in development mode, '/plandex-server' in production.", - "category": "General", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/db/fs.go:19", - "app/server/db/fs.go:25" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_BASE_DIR" - }, - "PLANDEX_ENV": { - "name": "PLANDEX_ENV", - "default": "development", - "description": "Set this to 'development' to default to the local development server instead of Plandex Cloud when working on Plandex itself.", - "category": "General", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/cli/api/clients.go:24", - "app/cli/fs/fs.go:33", - "app/cli/fs/fs.go:73", - "app/cli/fs/fs.go:122" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_ENV" - }, - "PORT": { - "name": "PORT", - "default": "8099", - "description": "The port the server listens on. Defaults to 8099.", - "category": "General", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/handlers/proxy_helper.go:48", - "app/server/setup/setup.go:85" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_PORT" - }, - "ANTHROPIC_API_KEY": { - "name": "ANTHROPIC_API_KEY", - "default": "", - "description": "Your Anthropic API key", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "ANTHROPIC_API_KEY" - }, - "AWS_ACCESS_KEY_ID": { - "name": "AWS_ACCESS_KEY_ID", - "default": "", - "description": "Your AWS access key ID", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AWS_ACCESS_KEY_ID" - }, - "AWS_INFERENCE_PROFILE_ARN": { - "name": "AWS_INFERENCE_PROFILE_ARN", - "default": "", - "description": "Your AWS inference profile ARN", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AWS_INFERENCE_PROFILE_ARN" - }, - "AWS_REGION": { - "name": "AWS_REGION", - "default": "", - "description": "Your AWS region", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AWS_REGION" - }, - "AWS_SECRET_ACCESS_KEY": { - "name": "AWS_SECRET_ACCESS_KEY", - "default": "", - "description": "Your AWS secret access key", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AWS_SECRET_ACCESS_KEY" - }, - "AWS_SESSION_TOKEN": { - "name": "AWS_SESSION_TOKEN", - "default": "", - "description": "Your AWS session token", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AWS_SESSION_TOKEN" - }, - "AZURE_API_BASE": { - "name": "AZURE_API_BASE", - "default": "", - "description": "Your Azure OpenAI API base URL", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AZURE_API_BASE" - }, - "AZURE_API_VERSION": { - "name": "AZURE_API_VERSION", - "default": "", - "description": "Your Azure OpenAI API version", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AZURE_API_VERSION" - }, - "AZURE_DEPLOYMENTS_MAP": { - "name": "AZURE_DEPLOYMENTS_MAP", - "default": "", - "description": "Your Azure OpenAI deployments map\u2014a JSON object mapping model names to deployment names (only needed if deployment names are different from model names)", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AZURE_DEPLOYMENTS_MAP" - }, - "AZURE_OPENAI_API_KEY": { - "name": "AZURE_OPENAI_API_KEY", - "default": "", - "description": "Your Azure OpenAI API key", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "AZURE_OPENAI_API_KEY" - }, - "DEEPSEEK_API_KEY": { - "name": "DEEPSEEK_API_KEY", - "default": "", - "description": "Your DeepSeek API key", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "DEEPSEEK_API_KEY" - }, - "GEMINI_API_KEY": { - "name": "GEMINI_API_KEY", - "default": "", - "description": "Your Google AI Studio API key", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "GEMINI_API_KEY" - }, - "GOOGLE_APPLICATION_CREDENTIALS": { - "name": "GOOGLE_APPLICATION_CREDENTIALS", - "default": "", - "description": "Your Google Vertex AI credentials file path", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "GOOGLE_APPLICATION_CREDENTIALS" - }, - "OPENAI_API_KEY": { - "name": "OPENAI_API_KEY", - "default": "", - "description": "Your OpenAI key", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "OPENAI_API_KEY" - }, - "OPENAI_ORG_ID": { - "name": "OPENAI_ORG_ID", - "default": "", - "description": "Your OpenAI organization ID. Defaults to empty.", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "OPENAI_ORG_ID" - }, - "OPENROUTER_API_KEY": { - "name": "OPENROUTER_API_KEY", - "default": "", - "description": "Your OpenRouter.ai API key", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "OPENROUTER_API_KEY" - }, - "PERPLEXITY_API_KEY": { - "name": "PERPLEXITY_API_KEY", - "default": "", - "description": "Your Perplexity API key", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "PERPLEXITY_API_KEY" - }, - "PLANDEX_AWS_PROFILE": { - "name": "PLANDEX_AWS_PROFILE", - "default": "", - "description": "Name of AWS profile in ~/.aws/credentials to use for AWS Bedrock. If not set, the credentials file won't be used.", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "CLEVERAGENTS_AWS_PROFILE" - }, - "VERTEXAI_LOCATION": { - "name": "VERTEXAI_LOCATION", - "default": "", - "description": "Your Google Vertex AI location", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "VERTEXAI_LOCATION" - }, - "VERTEXAI_PROJECT": { - "name": "VERTEXAI_PROJECT", - "default": "", - "description": "Your Google Vertex AI project ID", - "category": "LLM Providers", - "sources": [ - "documentation" - ], - "usage_locations": [], - "proposed_cleveragents_name": "VERTEXAI_PROJECT" - }, - "SMTP_HOST": { - "name": "SMTP_HOST", - "default": "", - "description": "Your SMTP host.", - "category": "SMTP", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/email/email.go:56" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_SMTP_HOST" - }, - "SMTP_PASSWORD": { - "name": "SMTP_PASSWORD", - "default": "", - "description": "SMTP password.", - "category": "SMTP", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/email/email.go:59" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_SMTP_PASSWORD" - }, - "SMTP_PORT": { - "name": "SMTP_PORT", - "default": "", - "description": "Set this to 1025 e.g. if you are using mailhog.", - "category": "SMTP", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/email/email.go:57" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_SMTP_PORT" - }, - "SMTP_USER": { - "name": "SMTP_USER", - "default": "", - "description": "SMTP username.", - "category": "SMTP", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/server/email/email.go:58" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_SMTP_USER" - }, - "APP_SUBDOMAIN": { - "name": "APP_SUBDOMAIN", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/handlers/auth_helpers.go:99", - "app/server/handlers/auth_helpers.go:146", - "app/server/handlers/auth_helpers.go:202" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_APP_SUBDOMAIN" - }, - "DB_HOST": { - "name": "DB_HOST", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/db/db.go:29", - "app/server/db/db.go:36" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_DB_HOST" - }, - "DB_NAME": { - "name": "DB_NAME", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/db/db.go:33", - "app/server/db/db.go:36" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_DB_NAME" - }, - "DB_PASSWORD": { - "name": "DB_PASSWORD", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/db/db.go:32", - "app/server/db/db.go:34" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_DB_PASSWORD" - }, - "DB_PORT": { - "name": "DB_PORT", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/db/db.go:30", - "app/server/db/db.go:36" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_DB_PORT" - }, - "DB_USER": { - "name": "DB_USER", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/db/db.go:31", - "app/server/db/db.go:36" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_DB_USER" - }, - "ECS_CONTAINER_METADATA_URI": { - "name": "ECS_CONTAINER_METADATA_URI", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/host/ip.go:48" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_ECS_CONTAINER_METADATA_URI" - }, - "HOME": { - "name": "HOME", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/model/litellm.go:122" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_HOME" - }, - "IP": { - "name": "IP", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/host/ip.go:31", - "app/server/host/ip.go:32" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_IP" - }, - "IS_CLOUD": { - "name": "IS_CLOUD", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/email/invite.go:20", - "app/server/email/verification.go:24", - "app/server/handlers/accounts.go:23", - "app/server/handlers/client_helper.go:72", - "app/server/handlers/models.go:39", - "app/server/handlers/models.go:46", - "app/server/handlers/models.go:127", - "app/server/handlers/models.go:213", - "app/server/handlers/models.go:245", - "app/server/handlers/models.go:437", - "app/server/handlers/orgs.go:58", - "app/server/handlers/settings.go:117", - "app/server/handlers/settings.go:137", - "app/server/host/ip.go:21", - "app/server/routes/routes.go:56" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_IS_CLOUD" - }, - "LITELLM_PROXY_DIR": { - "name": "LITELLM_PROXY_DIR", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/model/litellm.go:115", - "app/server/model/litellm.go:116" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_LITELLM_PROXY_DIR" - }, - "MIGRATIONS_DIR": { - "name": "MIGRATIONS_DIR", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/db/db.go:98", - "app/server/db/db.go:99" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_MIGRATIONS_DIR" - }, - "PATH": { - "name": "PATH", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/model/litellm.go:121" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_PATH" - }, - "PLANDEX_CLOUD": { - "name": "PLANDEX_CLOUD", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/db/settings_helpers.go:28", - "app/server/db/settings_helpers.go:114", - "app/server/db/settings_helpers.go:148" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_CLOUD" - }, - "SMTP_FROM": { - "name": "SMTP_FROM", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/email/email.go:60" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_SMTP_FROM" - }, - "VERBOSE_LOGGING": { - "name": "VERBOSE_LOGGING", - "default": "", - "description": "", - "category": "Server", - "sources": [ - "code" - ], - "usage_locations": [ - "app/server/syntax/file_map/map.go:15" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_VERBOSE_LOGGING" - }, - "PLANDEX_SKIP_UPGRADE": { - "name": "PLANDEX_SKIP_UPGRADE", - "default": "", - "description": "Set this to '1' to skip the auto-upgrade check when running the CLI.", - "category": "Upgrades", - "sources": [ - "documentation", - "code" - ], - "usage_locations": [ - "app/cli/upgrade.go:28" - ], - "proposed_cleveragents_name": "CLEVERAGENTS_SKIP_UPGRADE" - } - }, - "conflicts": [ - { - "old_name": "PLANDEX_ENV", - "new_name": "CLEVERAGENTS_ENV", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_API_HOST", - "new_name": "CLEVERAGENTS_API_HOST", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_AWS_PROFILE", - "new_name": "CLEVERAGENTS_AWS_PROFILE", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_SKIP_UPGRADE", - "new_name": "CLEVERAGENTS_SKIP_UPGRADE", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_OUT_DIR", - "new_name": "CLEVERAGENTS_OUT_DIR", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_DEV_CLI_OUT_DIR", - "new_name": "CLEVERAGENTS_DEV_CLI_OUT_DIR", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_DEV_CLI_OUT_DIR", - "new_name": "CLEVERAGENTS_DEV_CLI_OUT_DIR", - "type": "development_only", - "description": "Development-specific variable, may need reconsideration" - }, - { - "old_name": "PLANDEX_DEV_CLI_NAME", - "new_name": "CLEVERAGENTS_DEV_CLI_NAME", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_DEV_CLI_NAME", - "new_name": "CLEVERAGENTS_DEV_CLI_NAME", - "type": "development_only", - "description": "Development-specific variable, may need reconsideration" - }, - { - "old_name": "PLANDEX_DEV_CLI_ALIAS", - "new_name": "CLEVERAGENTS_DEV_CLI_ALIAS", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_DEV_CLI_ALIAS", - "new_name": "CLEVERAGENTS_DEV_CLI_ALIAS", - "type": "development_only", - "description": "Development-specific variable, may need reconsideration" - }, - { - "old_name": "PLANDEX_BASE_DIR", - "new_name": "CLEVERAGENTS_BASE_DIR", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_CLOUD", - "new_name": "CLEVERAGENTS_CLOUD", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_REPL_SESSION_ID", - "new_name": "CLEVERAGENTS_REPL_SESSION_ID", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_REPL", - "new_name": "CLEVERAGENTS_REPL", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_REPL_OUTPUT_FILE", - "new_name": "CLEVERAGENTS_REPL_OUTPUT_FILE", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_DISABLE_SUGGESTIONS", - "new_name": "CLEVERAGENTS_DISABLE_SUGGESTIONS", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_COLUMNS", - "new_name": "CLEVERAGENTS_COLUMNS", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - }, - { - "old_name": "PLANDEX_STREAM_FOREGROUND_COLOR", - "new_name": "CLEVERAGENTS_STREAM_FOREGROUND_COLOR", - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace" - } - ], - "mapping": { - "PLANDEX_ENV": "CLEVERAGENTS_ENV", - "PLANDEX_API_HOST": "CLEVERAGENTS_API_HOST", - "PLANDEX_AWS_PROFILE": "CLEVERAGENTS_AWS_PROFILE", - "PLANDEX_SKIP_UPGRADE": "CLEVERAGENTS_SKIP_UPGRADE", - "PLANDEX_OUT_DIR": "CLEVERAGENTS_OUT_DIR", - "PLANDEX_DEV_CLI_OUT_DIR": "CLEVERAGENTS_DEV_CLI_OUT_DIR", - "PLANDEX_DEV_CLI_NAME": "CLEVERAGENTS_DEV_CLI_NAME", - "PLANDEX_DEV_CLI_ALIAS": "CLEVERAGENTS_DEV_CLI_ALIAS", - "GOPATH": "CLEVERAGENTS_GOPATH", - "GOENV": "CLEVERAGENTS_GOENV", - "PLANDEX_BASE_DIR": "CLEVERAGENTS_BASE_DIR", - "API_HOST": "CLEVERAGENTS_API_HOST", - "PORT": "CLEVERAGENTS_PORT", - "DATABASE_URL": "CLEVERAGENTS_DATABASE_URL", - "LOCAL_MODE": "CLEVERAGENTS_LOCAL_MODE", - "OLLAMA_BASE_URL": "CLEVERAGENTS_OLLAMA_BASE_URL", - "SMTP_HOST": "CLEVERAGENTS_SMTP_HOST", - "SMTP_PORT": "CLEVERAGENTS_SMTP_PORT", - "SMTP_USER": "CLEVERAGENTS_SMTP_USER", - "SMTP_PASSWORD": "CLEVERAGENTS_SMTP_PASSWORD", - "DB_HOST": "CLEVERAGENTS_DB_HOST", - "DB_PORT": "CLEVERAGENTS_DB_PORT", - "DB_USER": "CLEVERAGENTS_DB_USER", - "DB_PASSWORD": "CLEVERAGENTS_DB_PASSWORD", - "DB_NAME": "CLEVERAGENTS_DB_NAME", - "MIGRATIONS_DIR": "CLEVERAGENTS_MIGRATIONS_DIR", - "PLANDEX_CLOUD": "CLEVERAGENTS_CLOUD", - "SMTP_FROM": "CLEVERAGENTS_SMTP_FROM", - "IS_CLOUD": "CLEVERAGENTS_IS_CLOUD", - "APP_SUBDOMAIN": "CLEVERAGENTS_APP_SUBDOMAIN", - "IP": "CLEVERAGENTS_IP", - "ECS_CONTAINER_METADATA_URI": "CLEVERAGENTS_ECS_CONTAINER_METADATA_URI", - "LITELLM_PROXY_DIR": "CLEVERAGENTS_LITELLM_PROXY_DIR", - "PATH": "CLEVERAGENTS_PATH", - "HOME": "CLEVERAGENTS_HOME", - "VERBOSE_LOGGING": "CLEVERAGENTS_VERBOSE_LOGGING", - "PLANDEX_REPL_SESSION_ID": "CLEVERAGENTS_REPL_SESSION_ID", - "EDITOR": "CLEVERAGENTS_EDITOR", - "VISUAL": "CLEVERAGENTS_VISUAL", - "PLANDEX_REPL": "CLEVERAGENTS_REPL", - "PLANDEX_REPL_OUTPUT_FILE": "CLEVERAGENTS_REPL_OUTPUT_FILE", - "GLAMOUR_STYLE": "CLEVERAGENTS_GLAMOUR_STYLE", - "PLANDEX_DISABLE_SUGGESTIONS": "CLEVERAGENTS_DISABLE_SUGGESTIONS", - "SHELL": "CLEVERAGENTS_SHELL", - "PLANDEX_COLUMNS": "CLEVERAGENTS_COLUMNS", - "COLUMNS": "CLEVERAGENTS_COLUMNS", - "PLANDEX_STREAM_FOREGROUND_COLOR": "CLEVERAGENTS_STREAM_FOREGROUND_COLOR" - }, - "statistics": { - "total_variables": 66, - "documented_variables": 39, - "code_only_variables": 27, - "migration_required": 16 - } -} \ No newline at end of file diff --git a/docs/reference/env_variables.yaml b/docs/reference/env_variables.yaml deleted file mode 100644 index 561afe5f3..000000000 --- a/docs/reference/env_variables.yaml +++ /dev/null @@ -1,1019 +0,0 @@ -variables: - COLUMNS: - name: COLUMNS - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/term/utils.go:109 - proposed_cleveragents_name: CLEVERAGENTS_COLUMNS - EDITOR: - name: EDITOR - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/cmd/plan_exec_helpers.go:41 - proposed_cleveragents_name: CLEVERAGENTS_EDITOR - GLAMOUR_STYLE: - name: GLAMOUR_STYLE - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/term/format.go:35 - proposed_cleveragents_name: CLEVERAGENTS_GLAMOUR_STYLE - PLANDEX_COLUMNS: - name: PLANDEX_COLUMNS - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/term/utils.go:88 - - app/cli/term/utils.go:89 - proposed_cleveragents_name: CLEVERAGENTS_COLUMNS - PLANDEX_DISABLE_SUGGESTIONS: - name: PLANDEX_DISABLE_SUGGESTIONS - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/term/help.go:180 - proposed_cleveragents_name: CLEVERAGENTS_DISABLE_SUGGESTIONS - PLANDEX_REPL: - name: PLANDEX_REPL - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/stream_tui/run.go:102 - - app/cli/term/repl.go:5 - proposed_cleveragents_name: CLEVERAGENTS_REPL - PLANDEX_REPL_OUTPUT_FILE: - name: PLANDEX_REPL_OUTPUT_FILE - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/stream_tui/run.go:102 - - app/cli/stream_tui/run.go:104 - proposed_cleveragents_name: CLEVERAGENTS_REPL_OUTPUT_FILE - PLANDEX_REPL_SESSION_ID: - name: PLANDEX_REPL_SESSION_ID - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/cmd/load.go:58 - - app/cli/cmd/usage.go:73 - - app/cli/cmd/usage.go:82 - - app/cli/cmd/usage.go:240 - - app/cli/cmd/usage.go:259 - - app/cli/plan_exec/tell.go:150 - proposed_cleveragents_name: CLEVERAGENTS_REPL_SESSION_ID - PLANDEX_STREAM_FOREGROUND_COLOR: - name: PLANDEX_STREAM_FOREGROUND_COLOR - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/term/utils.go:125 - - app/cli/term/utils.go:126 - proposed_cleveragents_name: CLEVERAGENTS_STREAM_FOREGROUND_COLOR - SHELL: - name: SHELL - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/term/os.go:15 - proposed_cleveragents_name: CLEVERAGENTS_SHELL - VISUAL: - name: VISUAL - default: '' - description: '' - category: CLI - sources: - - code - usage_locations: - - app/cli/cmd/plan_exec_helpers.go:43 - proposed_cleveragents_name: CLEVERAGENTS_VISUAL - GOPATH: - name: GOPATH - default: '' - description: This should be already set to your Go folder if you've installed - Golang. - category: Development - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: CLEVERAGENTS_GOPATH - PLANDEX_DEV_CLI_ALIAS: - name: PLANDEX_DEV_CLI_ALIAS - default: pdxd - description: The alias for the development binary when using dev.sh - category: Development - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: CLEVERAGENTS_DEV_CLI_ALIAS - PLANDEX_DEV_CLI_NAME: - name: PLANDEX_DEV_CLI_NAME - default: plandex-dev - description: The name of the development binary when using dev.sh - category: Development - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: CLEVERAGENTS_DEV_CLI_NAME - PLANDEX_DEV_CLI_OUT_DIR: - name: PLANDEX_DEV_CLI_OUT_DIR - default: /usr/local/bin - description: Where the development binary should be output when using dev.sh - category: Development - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: CLEVERAGENTS_DEV_CLI_OUT_DIR - PLANDEX_OUT_DIR: - name: PLANDEX_OUT_DIR - default: /usr/local/bin - description: Where the development binary should be output when using dev.sh - category: Development - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: CLEVERAGENTS_OUT_DIR - API_HOST: - name: API_HOST - default: '' - description: The host the API server listens on. Defaults to 'http://localhost:$PORT'. - In production mode, should be a host like 'https://api.your-domain.ai'. - category: General - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: CLEVERAGENTS_API_HOST - DATABASE_URL: - name: DATABASE_URL - default: '' - description: The URL of the PostgreSQL database. Defaults to 'postgres://plandex:plandex@plandex-postgres:5432/plandex?sslmode=disable' - in development mode - category: General - sources: - - documentation - - code - usage_locations: - - app/server/db/db.go:27 - proposed_cleveragents_name: CLEVERAGENTS_DATABASE_URL - GOENV: - name: GOENV - default: development - description: Whether to run in development or production mode. Must be 'development' - or 'production' - category: General - sources: - - documentation - - code - usage_locations: - - app/server/db/account_helpers.go:17 - - app/server/db/db.go:57 - - app/server/db/db.go:129 - - app/server/db/db.go:137 - - app/server/db/db.go:150 - - app/server/db/fs.go:20 - - app/server/db/fs.go:21 - - app/server/db/fs.go:28 - - app/server/email/invite.go:12 - - app/server/email/verification.go:14 - - app/server/email/verification.go:31 - - app/server/handlers/accounts.go:29 - - app/server/handlers/accounts.go:123 - - app/server/handlers/auth_helpers.go:98 - - app/server/handlers/auth_helpers.go:108 - - app/server/handlers/auth_helpers.go:145 - - app/server/handlers/auth_helpers.go:152 - - app/server/handlers/auth_helpers.go:201 - - app/server/handlers/auth_helpers.go:209 - - app/server/handlers/auth_helpers.go:260 - - app/server/handlers/auth_helpers.go:300 - - app/server/handlers/auth_helpers.go:436 - - app/server/handlers/invites.go:22 - - app/server/handlers/invites.go:165 - - app/server/handlers/invites.go:223 - - app/server/handlers/invites.go:281 - - app/server/handlers/invites.go:339 - - app/server/handlers/sessions.go:85 - - app/server/handlers/users.go:21 - - app/server/handlers/users.go:96 - - app/server/host/ip.go:16 - - app/server/model/client.go:538 - - app/server/setup/setup.go:67 - proposed_cleveragents_name: CLEVERAGENTS_GOENV - LOCAL_MODE: - name: LOCAL_MODE - default: '' - description: Whether to run in local mode - category: General - sources: - - documentation - - code - usage_locations: - - app/server/db/account_helpers.go:17 - - app/server/db/fs.go:21 - - app/server/handlers/accounts.go:29 - - app/server/handlers/accounts.go:123 - - app/server/handlers/auth_helpers.go:300 - - app/server/handlers/auth_helpers.go:436 - - app/server/handlers/invites.go:22 - - app/server/handlers/invites.go:165 - - app/server/handlers/invites.go:223 - - app/server/handlers/invites.go:281 - - app/server/handlers/invites.go:339 - - app/server/handlers/sessions.go:85 - - app/server/handlers/users.go:21 - - app/server/handlers/users.go:96 - proposed_cleveragents_name: CLEVERAGENTS_LOCAL_MODE - OLLAMA_BASE_URL: - name: OLLAMA_BASE_URL - default: '' - description: "The base URL of the Ollama server\u2014only need when the server\ - \ is running in a Docker container and needs to access Ollama models running\ - \ outside of the container" - category: General - sources: - - documentation - - code - usage_locations: - - app/server/model/client.go:295 - - app/server/model/client.go:296 - - app/server/model/litellm.go:125 - - app/server/model/litellm.go:128 - proposed_cleveragents_name: CLEVERAGENTS_OLLAMA_BASE_URL - PLANDEX_API_HOST: - name: PLANDEX_API_HOST - default: '' - description: "Defaults to 'http://localhost:8099' if PLANDEX_ENV is development,\ - \ otherwise it's 'https://api.plandex.ai'\u2014override this to use a different\ - \ host." - category: General - sources: - - documentation - - code - usage_locations: - - app/cli/api/clients.go:25 - proposed_cleveragents_name: CLEVERAGENTS_API_HOST - PLANDEX_BASE_DIR: - name: PLANDEX_BASE_DIR - default: '' - description: The base directory to read and write files. Defaults to '$HOME/plandex-server' - in development mode, '/plandex-server' in production. - category: General - sources: - - documentation - - code - usage_locations: - - app/server/db/fs.go:19 - - app/server/db/fs.go:25 - proposed_cleveragents_name: CLEVERAGENTS_BASE_DIR - PLANDEX_ENV: - name: PLANDEX_ENV - default: development - description: Set this to 'development' to default to the local development server - instead of Plandex Cloud when working on Plandex itself. - category: General - sources: - - documentation - - code - usage_locations: - - app/cli/api/clients.go:24 - - app/cli/fs/fs.go:33 - - app/cli/fs/fs.go:73 - - app/cli/fs/fs.go:122 - proposed_cleveragents_name: CLEVERAGENTS_ENV - PORT: - name: PORT - default: '8099' - description: The port the server listens on. Defaults to 8099. - category: General - sources: - - documentation - - code - usage_locations: - - app/server/handlers/proxy_helper.go:48 - - app/server/setup/setup.go:85 - proposed_cleveragents_name: CLEVERAGENTS_PORT - ANTHROPIC_API_KEY: - name: ANTHROPIC_API_KEY - default: '' - description: Your Anthropic API key - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: ANTHROPIC_API_KEY - AWS_ACCESS_KEY_ID: - name: AWS_ACCESS_KEY_ID - default: '' - description: Your AWS access key ID - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AWS_ACCESS_KEY_ID - AWS_INFERENCE_PROFILE_ARN: - name: AWS_INFERENCE_PROFILE_ARN - default: '' - description: Your AWS inference profile ARN - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AWS_INFERENCE_PROFILE_ARN - AWS_REGION: - name: AWS_REGION - default: '' - description: Your AWS region - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AWS_REGION - AWS_SECRET_ACCESS_KEY: - name: AWS_SECRET_ACCESS_KEY - default: '' - description: Your AWS secret access key - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AWS_SECRET_ACCESS_KEY - AWS_SESSION_TOKEN: - name: AWS_SESSION_TOKEN - default: '' - description: Your AWS session token - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AWS_SESSION_TOKEN - AZURE_API_BASE: - name: AZURE_API_BASE - default: '' - description: Your Azure OpenAI API base URL - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AZURE_API_BASE - AZURE_API_VERSION: - name: AZURE_API_VERSION - default: '' - description: Your Azure OpenAI API version - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AZURE_API_VERSION - AZURE_DEPLOYMENTS_MAP: - name: AZURE_DEPLOYMENTS_MAP - default: '' - description: "Your Azure OpenAI deployments map\u2014a JSON object mapping model\ - \ names to deployment names (only needed if deployment names are different from\ - \ model names)" - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AZURE_DEPLOYMENTS_MAP - AZURE_OPENAI_API_KEY: - name: AZURE_OPENAI_API_KEY - default: '' - description: Your Azure OpenAI API key - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: AZURE_OPENAI_API_KEY - DEEPSEEK_API_KEY: - name: DEEPSEEK_API_KEY - default: '' - description: Your DeepSeek API key - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: DEEPSEEK_API_KEY - GEMINI_API_KEY: - name: GEMINI_API_KEY - default: '' - description: Your Google AI Studio API key - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: GEMINI_API_KEY - GOOGLE_APPLICATION_CREDENTIALS: - name: GOOGLE_APPLICATION_CREDENTIALS - default: '' - description: Your Google Vertex AI credentials file path - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: GOOGLE_APPLICATION_CREDENTIALS - OPENAI_API_KEY: - name: OPENAI_API_KEY - default: '' - description: Your OpenAI key - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: OPENAI_API_KEY - OPENAI_ORG_ID: - name: OPENAI_ORG_ID - default: '' - description: Your OpenAI organization ID. Defaults to empty. - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: OPENAI_ORG_ID - OPENROUTER_API_KEY: - name: OPENROUTER_API_KEY - default: '' - description: Your OpenRouter.ai API key - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: OPENROUTER_API_KEY - CLEVERAGENTS_OPENROUTER_ORGANIZATION: - name: CLEVERAGENTS_OPENROUTER_ORGANIZATION - default: '' - description: Optional referrer/title that CleverAgents forwards as HTTP headers when calling OpenRouter. - category: LLM Providers - sources: - - python - usage_locations: - - src/cleveragents/config/settings.py:252 - - src/cleveragents/providers/llm/openrouter_provider.py:16 - proposed_cleveragents_name: CLEVERAGENTS_OPENROUTER_ORGANIZATION - CLEVERAGENTS_DEFAULT_PROVIDER: - name: CLEVERAGENTS_DEFAULT_PROVIDER - default: '' - description: Preferred provider slug (openai, anthropic, google, azure, openrouter, groq, together, cohere, gemini) that overrides auto-detected defaults. - category: LLM Providers - sources: - - python - usage_locations: - - src/cleveragents/config/settings.py:160 - - src/cleveragents/providers/registry.py:225 - proposed_cleveragents_name: CLEVERAGENTS_DEFAULT_PROVIDER - CLEVERAGENTS_DEFAULT_MODEL: - name: CLEVERAGENTS_DEFAULT_MODEL - default: '' - description: Optional global model override applied when CLI flags are omitted. - category: LLM Providers - sources: - - python - usage_locations: - - src/cleveragents/config/settings.py:165 - - src/cleveragents/providers/registry.py:222 - proposed_cleveragents_name: CLEVERAGENTS_DEFAULT_MODEL - PERPLEXITY_API_KEY: - name: PERPLEXITY_API_KEY - default: '' - description: Your Perplexity API key - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: PERPLEXITY_API_KEY - PLANDEX_AWS_PROFILE: - name: PLANDEX_AWS_PROFILE - default: '' - description: Name of AWS profile in ~/.aws/credentials to use for AWS Bedrock. - If not set, the credentials file won't be used. - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: CLEVERAGENTS_AWS_PROFILE - VERTEXAI_LOCATION: - name: VERTEXAI_LOCATION - default: '' - description: Your Google Vertex AI location - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: VERTEXAI_LOCATION - VERTEXAI_PROJECT: - name: VERTEXAI_PROJECT - default: '' - description: Your Google Vertex AI project ID - category: LLM Providers - sources: - - documentation - usage_locations: [] - proposed_cleveragents_name: VERTEXAI_PROJECT - SMTP_HOST: - name: SMTP_HOST - default: '' - description: Your SMTP host. - category: SMTP - sources: - - documentation - - code - usage_locations: - - app/server/email/email.go:56 - proposed_cleveragents_name: CLEVERAGENTS_SMTP_HOST - SMTP_PASSWORD: - name: SMTP_PASSWORD - default: '' - description: SMTP password. - category: SMTP - sources: - - documentation - - code - usage_locations: - - app/server/email/email.go:59 - proposed_cleveragents_name: CLEVERAGENTS_SMTP_PASSWORD - SMTP_PORT: - name: SMTP_PORT - default: '' - description: Set this to 1025 e.g. if you are using mailhog. - category: SMTP - sources: - - documentation - - code - usage_locations: - - app/server/email/email.go:57 - proposed_cleveragents_name: CLEVERAGENTS_SMTP_PORT - SMTP_USER: - name: SMTP_USER - default: '' - description: SMTP username. - category: SMTP - sources: - - documentation - - code - usage_locations: - - app/server/email/email.go:58 - proposed_cleveragents_name: CLEVERAGENTS_SMTP_USER - APP_SUBDOMAIN: - name: APP_SUBDOMAIN - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/handlers/auth_helpers.go:99 - - app/server/handlers/auth_helpers.go:146 - - app/server/handlers/auth_helpers.go:202 - proposed_cleveragents_name: CLEVERAGENTS_APP_SUBDOMAIN - DB_HOST: - name: DB_HOST - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/db/db.go:29 - - app/server/db/db.go:36 - proposed_cleveragents_name: CLEVERAGENTS_DB_HOST - DB_NAME: - name: DB_NAME - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/db/db.go:33 - - app/server/db/db.go:36 - proposed_cleveragents_name: CLEVERAGENTS_DB_NAME - DB_PASSWORD: - name: DB_PASSWORD - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/db/db.go:32 - - app/server/db/db.go:34 - proposed_cleveragents_name: CLEVERAGENTS_DB_PASSWORD - DB_PORT: - name: DB_PORT - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/db/db.go:30 - - app/server/db/db.go:36 - proposed_cleveragents_name: CLEVERAGENTS_DB_PORT - DB_USER: - name: DB_USER - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/db/db.go:31 - - app/server/db/db.go:36 - proposed_cleveragents_name: CLEVERAGENTS_DB_USER - ECS_CONTAINER_METADATA_URI: - name: ECS_CONTAINER_METADATA_URI - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/host/ip.go:48 - proposed_cleveragents_name: CLEVERAGENTS_ECS_CONTAINER_METADATA_URI - HOME: - name: HOME - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/model/litellm.go:122 - proposed_cleveragents_name: CLEVERAGENTS_HOME - IP: - name: IP - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/host/ip.go:31 - - app/server/host/ip.go:32 - proposed_cleveragents_name: CLEVERAGENTS_IP - IS_CLOUD: - name: IS_CLOUD - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/email/invite.go:20 - - app/server/email/verification.go:24 - - app/server/handlers/accounts.go:23 - - app/server/handlers/client_helper.go:72 - - app/server/handlers/models.go:39 - - app/server/handlers/models.go:46 - - app/server/handlers/models.go:127 - - app/server/handlers/models.go:213 - - app/server/handlers/models.go:245 - - app/server/handlers/models.go:437 - - app/server/handlers/orgs.go:58 - - app/server/handlers/settings.go:117 - - app/server/handlers/settings.go:137 - - app/server/host/ip.go:21 - - app/server/routes/routes.go:56 - proposed_cleveragents_name: CLEVERAGENTS_IS_CLOUD - LITELLM_PROXY_DIR: - name: LITELLM_PROXY_DIR - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/model/litellm.go:115 - - app/server/model/litellm.go:116 - proposed_cleveragents_name: CLEVERAGENTS_LITELLM_PROXY_DIR - MIGRATIONS_DIR: - name: MIGRATIONS_DIR - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/db/db.go:98 - - app/server/db/db.go:99 - proposed_cleveragents_name: CLEVERAGENTS_MIGRATIONS_DIR - PATH: - name: PATH - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/model/litellm.go:121 - proposed_cleveragents_name: CLEVERAGENTS_PATH - PLANDEX_CLOUD: - name: PLANDEX_CLOUD - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/db/settings_helpers.go:28 - - app/server/db/settings_helpers.go:114 - - app/server/db/settings_helpers.go:148 - proposed_cleveragents_name: CLEVERAGENTS_CLOUD - SMTP_FROM: - name: SMTP_FROM - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/email/email.go:60 - proposed_cleveragents_name: CLEVERAGENTS_SMTP_FROM - VERBOSE_LOGGING: - name: VERBOSE_LOGGING - default: '' - description: '' - category: Server - sources: - - code - usage_locations: - - app/server/syntax/file_map/map.go:15 - proposed_cleveragents_name: CLEVERAGENTS_VERBOSE_LOGGING - PLANDEX_SKIP_UPGRADE: - name: PLANDEX_SKIP_UPGRADE - default: '' - description: Set this to '1' to skip the auto-upgrade check when running the CLI. - category: Upgrades - sources: - - documentation - - code - usage_locations: - - app/cli/upgrade.go:28 - proposed_cleveragents_name: CLEVERAGENTS_SKIP_UPGRADE -conflicts: -- old_name: PLANDEX_ENV - new_name: CLEVERAGENTS_ENV - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_API_HOST - new_name: CLEVERAGENTS_API_HOST - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_AWS_PROFILE - new_name: CLEVERAGENTS_AWS_PROFILE - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_SKIP_UPGRADE - new_name: CLEVERAGENTS_SKIP_UPGRADE - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_OUT_DIR - new_name: CLEVERAGENTS_OUT_DIR - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_DEV_CLI_OUT_DIR - new_name: CLEVERAGENTS_DEV_CLI_OUT_DIR - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_DEV_CLI_OUT_DIR - new_name: CLEVERAGENTS_DEV_CLI_OUT_DIR - type: development_only - description: Development-specific variable, may need reconsideration -- old_name: PLANDEX_DEV_CLI_NAME - new_name: CLEVERAGENTS_DEV_CLI_NAME - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_DEV_CLI_NAME - new_name: CLEVERAGENTS_DEV_CLI_NAME - type: development_only - description: Development-specific variable, may need reconsideration -- old_name: PLANDEX_DEV_CLI_ALIAS - new_name: CLEVERAGENTS_DEV_CLI_ALIAS - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_DEV_CLI_ALIAS - new_name: CLEVERAGENTS_DEV_CLI_ALIAS - type: development_only - description: Development-specific variable, may need reconsideration -- old_name: PLANDEX_BASE_DIR - new_name: CLEVERAGENTS_BASE_DIR - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_CLOUD - new_name: CLEVERAGENTS_CLOUD - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_REPL_SESSION_ID - new_name: CLEVERAGENTS_REPL_SESSION_ID - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_REPL - new_name: CLEVERAGENTS_REPL - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_REPL_OUTPUT_FILE - new_name: CLEVERAGENTS_REPL_OUTPUT_FILE - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_DISABLE_SUGGESTIONS - new_name: CLEVERAGENTS_DISABLE_SUGGESTIONS - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_COLUMNS - new_name: CLEVERAGENTS_COLUMNS - type: migration_required - description: Rename from Plandex to CleverAgents namespace -- old_name: PLANDEX_STREAM_FOREGROUND_COLOR - new_name: CLEVERAGENTS_STREAM_FOREGROUND_COLOR - type: migration_required - description: Rename from Plandex to CleverAgents namespace -mapping: - PLANDEX_ENV: CLEVERAGENTS_ENV - PLANDEX_API_HOST: CLEVERAGENTS_API_HOST - PLANDEX_AWS_PROFILE: CLEVERAGENTS_AWS_PROFILE - PLANDEX_SKIP_UPGRADE: CLEVERAGENTS_SKIP_UPGRADE - PLANDEX_OUT_DIR: CLEVERAGENTS_OUT_DIR - PLANDEX_DEV_CLI_OUT_DIR: CLEVERAGENTS_DEV_CLI_OUT_DIR - PLANDEX_DEV_CLI_NAME: CLEVERAGENTS_DEV_CLI_NAME - PLANDEX_DEV_CLI_ALIAS: CLEVERAGENTS_DEV_CLI_ALIAS - GOPATH: CLEVERAGENTS_GOPATH - GOENV: CLEVERAGENTS_GOENV - PLANDEX_BASE_DIR: CLEVERAGENTS_BASE_DIR - API_HOST: CLEVERAGENTS_API_HOST - PORT: CLEVERAGENTS_PORT - DATABASE_URL: CLEVERAGENTS_DATABASE_URL - LOCAL_MODE: CLEVERAGENTS_LOCAL_MODE - OLLAMA_BASE_URL: CLEVERAGENTS_OLLAMA_BASE_URL - SMTP_HOST: CLEVERAGENTS_SMTP_HOST - SMTP_PORT: CLEVERAGENTS_SMTP_PORT - SMTP_USER: CLEVERAGENTS_SMTP_USER - SMTP_PASSWORD: CLEVERAGENTS_SMTP_PASSWORD - DB_HOST: CLEVERAGENTS_DB_HOST - DB_PORT: CLEVERAGENTS_DB_PORT - DB_USER: CLEVERAGENTS_DB_USER - DB_PASSWORD: CLEVERAGENTS_DB_PASSWORD - DB_NAME: CLEVERAGENTS_DB_NAME - MIGRATIONS_DIR: CLEVERAGENTS_MIGRATIONS_DIR - PLANDEX_CLOUD: CLEVERAGENTS_CLOUD - SMTP_FROM: CLEVERAGENTS_SMTP_FROM - IS_CLOUD: CLEVERAGENTS_IS_CLOUD - APP_SUBDOMAIN: CLEVERAGENTS_APP_SUBDOMAIN - IP: CLEVERAGENTS_IP - ECS_CONTAINER_METADATA_URI: CLEVERAGENTS_ECS_CONTAINER_METADATA_URI - LITELLM_PROXY_DIR: CLEVERAGENTS_LITELLM_PROXY_DIR - PATH: CLEVERAGENTS_PATH - HOME: CLEVERAGENTS_HOME - VERBOSE_LOGGING: CLEVERAGENTS_VERBOSE_LOGGING - PLANDEX_REPL_SESSION_ID: CLEVERAGENTS_REPL_SESSION_ID - EDITOR: CLEVERAGENTS_EDITOR - VISUAL: CLEVERAGENTS_VISUAL - PLANDEX_REPL: CLEVERAGENTS_REPL - PLANDEX_REPL_OUTPUT_FILE: CLEVERAGENTS_REPL_OUTPUT_FILE - GLAMOUR_STYLE: CLEVERAGENTS_GLAMOUR_STYLE - PLANDEX_DISABLE_SUGGESTIONS: CLEVERAGENTS_DISABLE_SUGGESTIONS - SHELL: CLEVERAGENTS_SHELL - PLANDEX_COLUMNS: CLEVERAGENTS_COLUMNS - COLUMNS: CLEVERAGENTS_COLUMNS - PLANDEX_STREAM_FOREGROUND_COLOR: CLEVERAGENTS_STREAM_FOREGROUND_COLOR -statistics: - total_variables: 69 - documented_variables: 42 - code_only_variables: 27 - migration_required: 16 -provider_capabilities: - description: | - CleverAgents derives provider behavior from `src/cleveragents/providers/registry.py`. - This section mirrors the runtime configuration so documentation consumers can see - which capabilities are available without digging into the code. - fallback_order: - - openai - - anthropic - - google - - azure - - openrouter - - groq - - together - - cohere - - gemini - precedence: - cli_flags: "--actor (required); defaults to actor registry" - environment: "CLEVERAGENTS_DEFAULT_PROVIDER / CLEVERAGENTS_DEFAULT_MODEL (used for built-in actors)" - settings: "Settings.default_provider / Settings.default_model (seed built-ins)" - auto: "Actor registry built-ins follow the fallback order when no default actor is set" - providers: - openai: - default_model: gpt-4o - supports_streaming: true - supports_tool_calls: true - supports_vision: true - supports_json_mode: true - max_context_length: 128000 - env_vars: - - OPENAI_API_KEY - anthropic: - default_model: claude-sonnet-4-20250514 - supports_streaming: true - supports_tool_calls: true - supports_vision: true - supports_json_mode: false - max_context_length: 200000 - env_vars: - - ANTHROPIC_API_KEY - google: - default_model: gemini-2.0-flash - supports_streaming: true - supports_tool_calls: true - supports_vision: true - supports_json_mode: true - max_context_length: 1000000 - env_vars: - - GOOGLE_API_KEY - - GOOGLE_GENAI_API_KEY - azure: - default_model: gpt-4o - supports_streaming: true - supports_tool_calls: true - supports_vision: true - supports_json_mode: true - max_context_length: 128000 - env_vars: - - AZURE_OPENAI_API_KEY - - AZURE_OPENAI_ENDPOINT - - AZURE_OPENAI_DEPLOYMENT - openrouter: - default_model: anthropic/claude-sonnet-4-20250514 - supports_streaming: true - supports_tool_calls: true - supports_vision: true - supports_json_mode: true - max_context_length: 128000 - env_vars: - - OPENROUTER_API_KEY - - CLEVERAGENTS_OPENROUTER_ORGANIZATION - groq: - default_model: llama-3.1-70b-versatile - supports_streaming: true - supports_tool_calls: true - supports_vision: false - supports_json_mode: true - max_context_length: 32000 - env_vars: - - GROQ_API_KEY - together: - default_model: meta-llama/Llama-3.1-70B-Instruct-Turbo - supports_streaming: true - supports_tool_calls: true - supports_vision: false - supports_json_mode: false - max_context_length: 32000 - env_vars: - - TOGETHER_API_KEY - cohere: - default_model: command-r-plus - supports_streaming: true - supports_tool_calls: true - supports_vision: false - supports_json_mode: false - max_context_length: 128000 - env_vars: - - COHERE_API_KEY - gemini: - default_model: gemini-2.0-flash - supports_streaming: true - supports_tool_calls: true - supports_vision: true - supports_json_mode: true - max_context_length: 1000000 - env_vars: - - GEMINI_API_KEY - - GOOGLE_GEMINI_API_KEY diff --git a/docs/reference/providers.md b/docs/reference/providers.md index ba4eea22c..ccd20d26e 100644 --- a/docs/reference/providers.md +++ b/docs/reference/providers.md @@ -16,7 +16,7 @@ CleverAgents routes every LangGraph workflow through the provider registry defin | Cohere | `COHERE_API_KEY` | `command-r-plus` | ✅ | ✅ | ❌ | ❌ | | Gemini (standalone) | `GEMINI_API_KEY` *or* `GOOGLE_GEMINI_API_KEY` | `gemini-2.0-flash` | ✅ | ✅ | ✅ | ✅ | -See `docs/reference/env_variables.yaml` for the full catalog (including AWS/Vertex-compatible aliases) and machine-readable capability metadata. +Keep this table in sync with provider capability metadata and required environment variables. ## Default selection logic diff --git a/docs/reference/server_api.yaml b/docs/reference/server_api.yaml deleted file mode 100644 index 747ba9934..000000000 --- a/docs/reference/server_api.yaml +++ /dev/null @@ -1,1539 +0,0 @@ -openapi: 3.0.0 -info: - title: CleverAgents API (Plandex Migration) - version: 1.0.0 - description: API specification extracted from Plandex server for CleverAgents migration -servers: -- url: http://localhost:8080 - description: Local development server -paths: - /health: - get: - summary: '' - operationId: HealthHandler - tags: - - System - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - /version: - get: - summary: '' - operationId: VersionHandler - tags: - - System - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - /accounts/sign_in: - post: - summary: '' - operationId: SignInHandler - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - /projects/{projectId}/plans/{planId}: - get: - summary: '' - operationId: GetPlanHandler - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - - name: planId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /projects/{projectId}/plans/{planId}/stream: - get: - summary: '' - operationId: PlanStreamHandler - tags: - - Plans - responses: - '200': - description: Successful response - content: - text/event-stream: - schema: - type: string - description: Server-sent events stream - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - - name: planId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - x-streaming: true - /projects/{projectId}/models: - get: - summary: '' - operationId: ListModelsHandler - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /models: - get: - summary: '' - operationId: ModelsListHandler - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/1: - get: - summary: '' - operationId: PlansHandler1 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/2: - get: - summary: '' - operationId: ProjectsHandler2 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/3: - post: - summary: '' - operationId: ModelsHandler3 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/4: - get: - summary: '' - operationId: AuthenticationHandler4 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/{planId}/5: - get: - summary: '' - operationId: PlansHandler5 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - - name: planId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/6: - post: - summary: '' - operationId: ProjectsHandler6 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/7: - get: - summary: '' - operationId: ModelsHandler7 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/8: - get: - summary: '' - operationId: AuthenticationHandler8 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/9: - post: - summary: '' - operationId: PlansHandler9 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/10: - get: - summary: '' - operationId: ProjectsHandler10 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/11: - get: - summary: '' - operationId: ModelsHandler11 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/12: - post: - summary: '' - operationId: AuthenticationHandler12 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/13: - get: - summary: '' - operationId: PlansHandler13 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/14: - get: - summary: '' - operationId: ProjectsHandler14 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/15: - post: - summary: '' - operationId: ModelsHandler15 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/16: - get: - summary: '' - operationId: AuthenticationHandler16 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/17: - get: - summary: '' - operationId: PlansHandler17 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/18: - post: - summary: '' - operationId: ProjectsHandler18 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/19: - get: - summary: '' - operationId: ModelsHandler19 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/20: - get: - summary: '' - operationId: AuthenticationHandler20 - tags: - - Authentication - responses: - '200': - description: Successful response - content: - text/event-stream: - schema: - type: string - description: Server-sent events stream - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - x-streaming: true - /api/plans/{projectId}/21: - post: - summary: '' - operationId: PlansHandler21 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/22: - get: - summary: '' - operationId: ProjectsHandler22 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/23: - get: - summary: '' - operationId: ModelsHandler23 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/24: - post: - summary: '' - operationId: AuthenticationHandler24 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/{planId}/25: - get: - summary: '' - operationId: PlansHandler25 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - - name: planId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/26: - get: - summary: '' - operationId: ProjectsHandler26 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/27: - post: - summary: '' - operationId: ModelsHandler27 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/28: - get: - summary: '' - operationId: AuthenticationHandler28 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/29: - get: - summary: '' - operationId: PlansHandler29 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/30: - post: - summary: '' - operationId: ProjectsHandler30 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/31: - get: - summary: '' - operationId: ModelsHandler31 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/32: - get: - summary: '' - operationId: AuthenticationHandler32 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/33: - post: - summary: '' - operationId: PlansHandler33 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/34: - get: - summary: '' - operationId: ProjectsHandler34 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/35: - get: - summary: '' - operationId: ModelsHandler35 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/36: - post: - summary: '' - operationId: AuthenticationHandler36 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/37: - get: - summary: '' - operationId: PlansHandler37 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/38: - get: - summary: '' - operationId: ProjectsHandler38 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/39: - post: - summary: '' - operationId: ModelsHandler39 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/40: - get: - summary: '' - operationId: AuthenticationHandler40 - tags: - - Authentication - responses: - '200': - description: Successful response - content: - text/event-stream: - schema: - type: string - description: Server-sent events stream - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - x-streaming: true - /api/plans/{projectId}/41: - get: - summary: '' - operationId: PlansHandler41 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/42: - post: - summary: '' - operationId: ProjectsHandler42 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/43: - get: - summary: '' - operationId: ModelsHandler43 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/44: - get: - summary: '' - operationId: AuthenticationHandler44 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/{planId}/45: - post: - summary: '' - operationId: PlansHandler45 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - - name: planId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/46: - get: - summary: '' - operationId: ProjectsHandler46 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/47: - get: - summary: '' - operationId: ModelsHandler47 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/48: - post: - summary: '' - operationId: AuthenticationHandler48 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/49: - get: - summary: '' - operationId: PlansHandler49 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/50: - get: - summary: '' - operationId: ProjectsHandler50 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/51: - post: - summary: '' - operationId: ModelsHandler51 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/52: - get: - summary: '' - operationId: AuthenticationHandler52 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/53: - get: - summary: '' - operationId: PlansHandler53 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/54: - post: - summary: '' - operationId: ProjectsHandler54 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/55: - get: - summary: '' - operationId: ModelsHandler55 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/56: - get: - summary: '' - operationId: AuthenticationHandler56 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/57: - post: - summary: '' - operationId: PlansHandler57 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/58: - get: - summary: '' - operationId: ProjectsHandler58 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/59: - get: - summary: '' - operationId: ModelsHandler59 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/60: - post: - summary: '' - operationId: AuthenticationHandler60 - tags: - - Authentication - responses: - '200': - description: Successful response - content: - text/event-stream: - schema: - type: string - description: Server-sent events stream - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - x-streaming: true - /api/plans/{projectId}/61: - get: - summary: '' - operationId: PlansHandler61 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/62: - get: - summary: '' - operationId: ProjectsHandler62 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/63: - post: - summary: '' - operationId: ModelsHandler63 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/64: - get: - summary: '' - operationId: AuthenticationHandler64 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/{planId}/65: - get: - summary: '' - operationId: PlansHandler65 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - - name: planId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/66: - post: - summary: '' - operationId: ProjectsHandler66 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/67: - get: - summary: '' - operationId: ModelsHandler67 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/68: - get: - summary: '' - operationId: AuthenticationHandler68 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/69: - post: - summary: '' - operationId: PlansHandler69 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/70: - get: - summary: '' - operationId: ProjectsHandler70 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/71: - get: - summary: '' - operationId: ModelsHandler71 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/authentication/72: - post: - summary: '' - operationId: AuthenticationHandler72 - tags: - - Authentication - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] - /api/plans/{projectId}/73: - get: - summary: '' - operationId: PlansHandler73 - tags: - - Plans - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/projects/{projectId}/74: - get: - summary: '' - operationId: ProjectsHandler74 - tags: - - Projects - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - parameters: - - name: projectId - in: path - required: true - schema: - type: string - security: - - sessionAuth: [] - /api/models/75: - post: - summary: '' - operationId: ModelsHandler75 - tags: - - Models - responses: - '200': - description: Successful response - '401': - description: Unauthorized - '500': - description: Internal server error - security: - - sessionAuth: [] -components: - securitySchemes: - sessionAuth: - type: apiKey - in: header - name: Authorization diff --git a/docs/reference/server_endpoints.json b/docs/reference/server_endpoints.json deleted file mode 100644 index 9d64ce476..000000000 --- a/docs/reference/server_endpoints.json +++ /dev/null @@ -1,1846 +0,0 @@ -{ - "metadata": { - "source": "/app/plandex/app/server", - "endpoints_count": 82, - "categories_count": 5 - }, - "statistics": { - "total_endpoints": 82, - "streaming_endpoints": 4, - "categories": 5, - "methods": { - "GET": 56, - "POST": 26 - } - }, - "endpoints_by_category": { - "System": [ - { - "path": "/health", - "method": "GET", - "handler": "HealthHandler", - "is_streaming": false, - "requires_auth": false, - "path_params": [], - "description": "", - "category": "System" - }, - { - "path": "/version", - "method": "GET", - "handler": "VersionHandler", - "is_streaming": false, - "requires_auth": false, - "path_params": [], - "description": "", - "category": "System" - } - ], - "Authentication": [ - { - "path": "/accounts/sign_in", - "method": "POST", - "handler": "SignInHandler", - "is_streaming": false, - "requires_auth": false, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/4", - "method": "GET", - "handler": "AuthenticationHandler4", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/8", - "method": "GET", - "handler": "AuthenticationHandler8", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/12", - "method": "POST", - "handler": "AuthenticationHandler12", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/16", - "method": "GET", - "handler": "AuthenticationHandler16", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/20", - "method": "GET", - "handler": "AuthenticationHandler20", - "is_streaming": true, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/24", - "method": "POST", - "handler": "AuthenticationHandler24", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/28", - "method": "GET", - "handler": "AuthenticationHandler28", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/32", - "method": "GET", - "handler": "AuthenticationHandler32", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/36", - "method": "POST", - "handler": "AuthenticationHandler36", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/40", - "method": "GET", - "handler": "AuthenticationHandler40", - "is_streaming": true, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/44", - "method": "GET", - "handler": "AuthenticationHandler44", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/48", - "method": "POST", - "handler": "AuthenticationHandler48", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/52", - "method": "GET", - "handler": "AuthenticationHandler52", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/56", - "method": "GET", - "handler": "AuthenticationHandler56", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/60", - "method": "POST", - "handler": "AuthenticationHandler60", - "is_streaming": true, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/64", - "method": "GET", - "handler": "AuthenticationHandler64", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/68", - "method": "GET", - "handler": "AuthenticationHandler68", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/authentication/72", - "method": "POST", - "handler": "AuthenticationHandler72", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - } - ], - "Plans": [ - { - "path": "/projects/{projectId}/plans/{planId}", - "method": "GET", - "handler": "GetPlanHandler", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/projects/{projectId}/plans/{planId}/stream", - "method": "GET", - "handler": "PlanStreamHandler", - "is_streaming": true, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/1", - "method": "GET", - "handler": "PlansHandler1", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/{planId}/5", - "method": "GET", - "handler": "PlansHandler5", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/9", - "method": "POST", - "handler": "PlansHandler9", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/13", - "method": "GET", - "handler": "PlansHandler13", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/17", - "method": "GET", - "handler": "PlansHandler17", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/21", - "method": "POST", - "handler": "PlansHandler21", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/{planId}/25", - "method": "GET", - "handler": "PlansHandler25", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/29", - "method": "GET", - "handler": "PlansHandler29", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/33", - "method": "POST", - "handler": "PlansHandler33", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/37", - "method": "GET", - "handler": "PlansHandler37", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/41", - "method": "GET", - "handler": "PlansHandler41", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/{planId}/45", - "method": "POST", - "handler": "PlansHandler45", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/49", - "method": "GET", - "handler": "PlansHandler49", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/53", - "method": "GET", - "handler": "PlansHandler53", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/57", - "method": "POST", - "handler": "PlansHandler57", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/61", - "method": "GET", - "handler": "PlansHandler61", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/{planId}/65", - "method": "GET", - "handler": "PlansHandler65", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/69", - "method": "POST", - "handler": "PlansHandler69", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/plans/{projectId}/73", - "method": "GET", - "handler": "PlansHandler73", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - } - ], - "Models": [ - { - "path": "/projects/{projectId}/models", - "method": "GET", - "handler": "ListModelsHandler", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Models" - }, - { - "path": "/models", - "method": "GET", - "handler": "ModelsListHandler", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/3", - "method": "POST", - "handler": "ModelsHandler3", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/7", - "method": "GET", - "handler": "ModelsHandler7", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/11", - "method": "GET", - "handler": "ModelsHandler11", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/15", - "method": "POST", - "handler": "ModelsHandler15", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/19", - "method": "GET", - "handler": "ModelsHandler19", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/23", - "method": "GET", - "handler": "ModelsHandler23", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/27", - "method": "POST", - "handler": "ModelsHandler27", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/31", - "method": "GET", - "handler": "ModelsHandler31", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/35", - "method": "GET", - "handler": "ModelsHandler35", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/39", - "method": "POST", - "handler": "ModelsHandler39", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/43", - "method": "GET", - "handler": "ModelsHandler43", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/47", - "method": "GET", - "handler": "ModelsHandler47", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/51", - "method": "POST", - "handler": "ModelsHandler51", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/55", - "method": "GET", - "handler": "ModelsHandler55", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/59", - "method": "GET", - "handler": "ModelsHandler59", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/63", - "method": "POST", - "handler": "ModelsHandler63", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/67", - "method": "GET", - "handler": "ModelsHandler67", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/71", - "method": "GET", - "handler": "ModelsHandler71", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/models/75", - "method": "POST", - "handler": "ModelsHandler75", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - } - ], - "Projects": [ - { - "path": "/api/projects/{projectId}/2", - "method": "GET", - "handler": "ProjectsHandler2", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/6", - "method": "POST", - "handler": "ProjectsHandler6", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/10", - "method": "GET", - "handler": "ProjectsHandler10", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/14", - "method": "GET", - "handler": "ProjectsHandler14", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/18", - "method": "POST", - "handler": "ProjectsHandler18", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/22", - "method": "GET", - "handler": "ProjectsHandler22", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/26", - "method": "GET", - "handler": "ProjectsHandler26", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/30", - "method": "POST", - "handler": "ProjectsHandler30", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/34", - "method": "GET", - "handler": "ProjectsHandler34", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/38", - "method": "GET", - "handler": "ProjectsHandler38", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/42", - "method": "POST", - "handler": "ProjectsHandler42", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/46", - "method": "GET", - "handler": "ProjectsHandler46", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/50", - "method": "GET", - "handler": "ProjectsHandler50", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/54", - "method": "POST", - "handler": "ProjectsHandler54", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/58", - "method": "GET", - "handler": "ProjectsHandler58", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/62", - "method": "GET", - "handler": "ProjectsHandler62", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/66", - "method": "POST", - "handler": "ProjectsHandler66", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/70", - "method": "GET", - "handler": "ProjectsHandler70", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/projects/{projectId}/74", - "method": "GET", - "handler": "ProjectsHandler74", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - } - ] - }, - "all_endpoints": [ - { - "path": "/health", - "method": "GET", - "handler": "HealthHandler", - "is_streaming": false, - "requires_auth": false, - "path_params": [], - "description": "", - "category": "System" - }, - { - "path": "/version", - "method": "GET", - "handler": "VersionHandler", - "is_streaming": false, - "requires_auth": false, - "path_params": [], - "description": "", - "category": "System" - }, - { - "path": "/accounts/sign_in", - "method": "POST", - "handler": "SignInHandler", - "is_streaming": false, - "requires_auth": false, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/projects/{projectId}/plans/{planId}", - "method": "GET", - "handler": "GetPlanHandler", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/projects/{projectId}/plans/{planId}/stream", - "method": "GET", - "handler": "PlanStreamHandler", - "is_streaming": true, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/projects/{projectId}/models", - "method": "GET", - "handler": "ListModelsHandler", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Models" - }, - { - "path": "/models", - "method": "GET", - "handler": "ModelsListHandler", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/plans/{projectId}/1", - "method": "GET", - "handler": "PlansHandler1", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/2", - "method": "GET", - "handler": "ProjectsHandler2", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/3", - "method": "POST", - "handler": "ModelsHandler3", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/4", - "method": "GET", - "handler": "AuthenticationHandler4", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/{planId}/5", - "method": "GET", - "handler": "PlansHandler5", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/6", - "method": "POST", - "handler": "ProjectsHandler6", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/7", - "method": "GET", - "handler": "ModelsHandler7", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/8", - "method": "GET", - "handler": "AuthenticationHandler8", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/9", - "method": "POST", - "handler": "PlansHandler9", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/10", - "method": "GET", - "handler": "ProjectsHandler10", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/11", - "method": "GET", - "handler": "ModelsHandler11", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/12", - "method": "POST", - "handler": "AuthenticationHandler12", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/13", - "method": "GET", - "handler": "PlansHandler13", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/14", - "method": "GET", - "handler": "ProjectsHandler14", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/15", - "method": "POST", - "handler": "ModelsHandler15", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/16", - "method": "GET", - "handler": "AuthenticationHandler16", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/17", - "method": "GET", - "handler": "PlansHandler17", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/18", - "method": "POST", - "handler": "ProjectsHandler18", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/19", - "method": "GET", - "handler": "ModelsHandler19", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/20", - "method": "GET", - "handler": "AuthenticationHandler20", - "is_streaming": true, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/21", - "method": "POST", - "handler": "PlansHandler21", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/22", - "method": "GET", - "handler": "ProjectsHandler22", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/23", - "method": "GET", - "handler": "ModelsHandler23", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/24", - "method": "POST", - "handler": "AuthenticationHandler24", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/{planId}/25", - "method": "GET", - "handler": "PlansHandler25", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/26", - "method": "GET", - "handler": "ProjectsHandler26", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/27", - "method": "POST", - "handler": "ModelsHandler27", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/28", - "method": "GET", - "handler": "AuthenticationHandler28", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/29", - "method": "GET", - "handler": "PlansHandler29", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/30", - "method": "POST", - "handler": "ProjectsHandler30", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/31", - "method": "GET", - "handler": "ModelsHandler31", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/32", - "method": "GET", - "handler": "AuthenticationHandler32", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/33", - "method": "POST", - "handler": "PlansHandler33", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/34", - "method": "GET", - "handler": "ProjectsHandler34", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/35", - "method": "GET", - "handler": "ModelsHandler35", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/36", - "method": "POST", - "handler": "AuthenticationHandler36", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/37", - "method": "GET", - "handler": "PlansHandler37", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/38", - "method": "GET", - "handler": "ProjectsHandler38", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/39", - "method": "POST", - "handler": "ModelsHandler39", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/40", - "method": "GET", - "handler": "AuthenticationHandler40", - "is_streaming": true, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/41", - "method": "GET", - "handler": "PlansHandler41", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/42", - "method": "POST", - "handler": "ProjectsHandler42", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/43", - "method": "GET", - "handler": "ModelsHandler43", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/44", - "method": "GET", - "handler": "AuthenticationHandler44", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/{planId}/45", - "method": "POST", - "handler": "PlansHandler45", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/46", - "method": "GET", - "handler": "ProjectsHandler46", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/47", - "method": "GET", - "handler": "ModelsHandler47", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/48", - "method": "POST", - "handler": "AuthenticationHandler48", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/49", - "method": "GET", - "handler": "PlansHandler49", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/50", - "method": "GET", - "handler": "ProjectsHandler50", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/51", - "method": "POST", - "handler": "ModelsHandler51", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/52", - "method": "GET", - "handler": "AuthenticationHandler52", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/53", - "method": "GET", - "handler": "PlansHandler53", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/54", - "method": "POST", - "handler": "ProjectsHandler54", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/55", - "method": "GET", - "handler": "ModelsHandler55", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/56", - "method": "GET", - "handler": "AuthenticationHandler56", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/57", - "method": "POST", - "handler": "PlansHandler57", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/58", - "method": "GET", - "handler": "ProjectsHandler58", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/59", - "method": "GET", - "handler": "ModelsHandler59", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/60", - "method": "POST", - "handler": "AuthenticationHandler60", - "is_streaming": true, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/61", - "method": "GET", - "handler": "PlansHandler61", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/62", - "method": "GET", - "handler": "ProjectsHandler62", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/63", - "method": "POST", - "handler": "ModelsHandler63", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/64", - "method": "GET", - "handler": "AuthenticationHandler64", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/{planId}/65", - "method": "GET", - "handler": "PlansHandler65", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId", - "planId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/66", - "method": "POST", - "handler": "ProjectsHandler66", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/67", - "method": "GET", - "handler": "ModelsHandler67", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/68", - "method": "GET", - "handler": "AuthenticationHandler68", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/69", - "method": "POST", - "handler": "PlansHandler69", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/70", - "method": "GET", - "handler": "ProjectsHandler70", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/71", - "method": "GET", - "handler": "ModelsHandler71", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - }, - { - "path": "/api/authentication/72", - "method": "POST", - "handler": "AuthenticationHandler72", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Authentication" - }, - { - "path": "/api/plans/{projectId}/73", - "method": "GET", - "handler": "PlansHandler73", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Plans" - }, - { - "path": "/api/projects/{projectId}/74", - "method": "GET", - "handler": "ProjectsHandler74", - "is_streaming": false, - "requires_auth": true, - "path_params": [ - "projectId" - ], - "description": "", - "category": "Projects" - }, - { - "path": "/api/models/75", - "method": "POST", - "handler": "ModelsHandler75", - "is_streaming": false, - "requires_auth": true, - "path_params": [], - "description": "", - "category": "Models" - } - ] -} \ No newline at end of file diff --git a/docs/reference/server_endpoints.yaml b/docs/reference/server_endpoints.yaml deleted file mode 100644 index 54b3bf516..000000000 --- a/docs/reference/server_endpoints.yaml +++ /dev/null @@ -1,1424 +0,0 @@ -metadata: - source: /app/plandex/app/server - endpoints_count: 82 - categories_count: 5 -statistics: - total_endpoints: 82 - streaming_endpoints: 4 - categories: 5 - methods: - GET: 56 - POST: 26 -endpoints_by_category: - System: - - path: /health - method: GET - handler: HealthHandler - is_streaming: false - requires_auth: false - path_params: [] - description: '' - category: System - - path: /version - method: GET - handler: VersionHandler - is_streaming: false - requires_auth: false - path_params: [] - description: '' - category: System - Authentication: - - path: /accounts/sign_in - method: POST - handler: SignInHandler - is_streaming: false - requires_auth: false - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/4 - method: GET - handler: AuthenticationHandler4 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/8 - method: GET - handler: AuthenticationHandler8 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/12 - method: POST - handler: AuthenticationHandler12 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/16 - method: GET - handler: AuthenticationHandler16 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/20 - method: GET - handler: AuthenticationHandler20 - is_streaming: true - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/24 - method: POST - handler: AuthenticationHandler24 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/28 - method: GET - handler: AuthenticationHandler28 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/32 - method: GET - handler: AuthenticationHandler32 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/36 - method: POST - handler: AuthenticationHandler36 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/40 - method: GET - handler: AuthenticationHandler40 - is_streaming: true - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/44 - method: GET - handler: AuthenticationHandler44 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/48 - method: POST - handler: AuthenticationHandler48 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/52 - method: GET - handler: AuthenticationHandler52 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/56 - method: GET - handler: AuthenticationHandler56 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/60 - method: POST - handler: AuthenticationHandler60 - is_streaming: true - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/64 - method: GET - handler: AuthenticationHandler64 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/68 - method: GET - handler: AuthenticationHandler68 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - - path: /api/authentication/72 - method: POST - handler: AuthenticationHandler72 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication - Plans: - - path: /projects/{projectId}/plans/{planId} - method: GET - handler: GetPlanHandler - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans - - path: /projects/{projectId}/plans/{planId}/stream - method: GET - handler: PlanStreamHandler - is_streaming: true - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans - - path: /api/plans/{projectId}/1 - method: GET - handler: PlansHandler1 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/{planId}/5 - method: GET - handler: PlansHandler5 - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans - - path: /api/plans/{projectId}/9 - method: POST - handler: PlansHandler9 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/13 - method: GET - handler: PlansHandler13 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/17 - method: GET - handler: PlansHandler17 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/21 - method: POST - handler: PlansHandler21 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/{planId}/25 - method: GET - handler: PlansHandler25 - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans - - path: /api/plans/{projectId}/29 - method: GET - handler: PlansHandler29 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/33 - method: POST - handler: PlansHandler33 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/37 - method: GET - handler: PlansHandler37 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/41 - method: GET - handler: PlansHandler41 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/{planId}/45 - method: POST - handler: PlansHandler45 - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans - - path: /api/plans/{projectId}/49 - method: GET - handler: PlansHandler49 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/53 - method: GET - handler: PlansHandler53 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/57 - method: POST - handler: PlansHandler57 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/61 - method: GET - handler: PlansHandler61 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/{planId}/65 - method: GET - handler: PlansHandler65 - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans - - path: /api/plans/{projectId}/69 - method: POST - handler: PlansHandler69 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - - path: /api/plans/{projectId}/73 - method: GET - handler: PlansHandler73 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans - Models: - - path: /projects/{projectId}/models - method: GET - handler: ListModelsHandler - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Models - - path: /models - method: GET - handler: ModelsListHandler - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/3 - method: POST - handler: ModelsHandler3 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/7 - method: GET - handler: ModelsHandler7 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/11 - method: GET - handler: ModelsHandler11 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/15 - method: POST - handler: ModelsHandler15 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/19 - method: GET - handler: ModelsHandler19 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/23 - method: GET - handler: ModelsHandler23 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/27 - method: POST - handler: ModelsHandler27 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/31 - method: GET - handler: ModelsHandler31 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/35 - method: GET - handler: ModelsHandler35 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/39 - method: POST - handler: ModelsHandler39 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/43 - method: GET - handler: ModelsHandler43 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/47 - method: GET - handler: ModelsHandler47 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/51 - method: POST - handler: ModelsHandler51 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/55 - method: GET - handler: ModelsHandler55 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/59 - method: GET - handler: ModelsHandler59 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/63 - method: POST - handler: ModelsHandler63 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/67 - method: GET - handler: ModelsHandler67 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/71 - method: GET - handler: ModelsHandler71 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - - path: /api/models/75 - method: POST - handler: ModelsHandler75 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models - Projects: - - path: /api/projects/{projectId}/2 - method: GET - handler: ProjectsHandler2 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/6 - method: POST - handler: ProjectsHandler6 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/10 - method: GET - handler: ProjectsHandler10 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/14 - method: GET - handler: ProjectsHandler14 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/18 - method: POST - handler: ProjectsHandler18 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/22 - method: GET - handler: ProjectsHandler22 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/26 - method: GET - handler: ProjectsHandler26 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/30 - method: POST - handler: ProjectsHandler30 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/34 - method: GET - handler: ProjectsHandler34 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/38 - method: GET - handler: ProjectsHandler38 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/42 - method: POST - handler: ProjectsHandler42 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/46 - method: GET - handler: ProjectsHandler46 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/50 - method: GET - handler: ProjectsHandler50 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/54 - method: POST - handler: ProjectsHandler54 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/58 - method: GET - handler: ProjectsHandler58 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/62 - method: GET - handler: ProjectsHandler62 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/66 - method: POST - handler: ProjectsHandler66 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/70 - method: GET - handler: ProjectsHandler70 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects - - path: /api/projects/{projectId}/74 - method: GET - handler: ProjectsHandler74 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -all_endpoints: -- path: /health - method: GET - handler: HealthHandler - is_streaming: false - requires_auth: false - path_params: [] - description: '' - category: System -- path: /version - method: GET - handler: VersionHandler - is_streaming: false - requires_auth: false - path_params: [] - description: '' - category: System -- path: /accounts/sign_in - method: POST - handler: SignInHandler - is_streaming: false - requires_auth: false - path_params: [] - description: '' - category: Authentication -- path: /projects/{projectId}/plans/{planId} - method: GET - handler: GetPlanHandler - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans -- path: /projects/{projectId}/plans/{planId}/stream - method: GET - handler: PlanStreamHandler - is_streaming: true - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans -- path: /projects/{projectId}/models - method: GET - handler: ListModelsHandler - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Models -- path: /models - method: GET - handler: ModelsListHandler - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/plans/{projectId}/1 - method: GET - handler: PlansHandler1 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/2 - method: GET - handler: ProjectsHandler2 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/3 - method: POST - handler: ModelsHandler3 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/4 - method: GET - handler: AuthenticationHandler4 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/{planId}/5 - method: GET - handler: PlansHandler5 - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans -- path: /api/projects/{projectId}/6 - method: POST - handler: ProjectsHandler6 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/7 - method: GET - handler: ModelsHandler7 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/8 - method: GET - handler: AuthenticationHandler8 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/9 - method: POST - handler: PlansHandler9 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/10 - method: GET - handler: ProjectsHandler10 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/11 - method: GET - handler: ModelsHandler11 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/12 - method: POST - handler: AuthenticationHandler12 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/13 - method: GET - handler: PlansHandler13 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/14 - method: GET - handler: ProjectsHandler14 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/15 - method: POST - handler: ModelsHandler15 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/16 - method: GET - handler: AuthenticationHandler16 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/17 - method: GET - handler: PlansHandler17 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/18 - method: POST - handler: ProjectsHandler18 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/19 - method: GET - handler: ModelsHandler19 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/20 - method: GET - handler: AuthenticationHandler20 - is_streaming: true - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/21 - method: POST - handler: PlansHandler21 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/22 - method: GET - handler: ProjectsHandler22 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/23 - method: GET - handler: ModelsHandler23 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/24 - method: POST - handler: AuthenticationHandler24 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/{planId}/25 - method: GET - handler: PlansHandler25 - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans -- path: /api/projects/{projectId}/26 - method: GET - handler: ProjectsHandler26 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/27 - method: POST - handler: ModelsHandler27 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/28 - method: GET - handler: AuthenticationHandler28 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/29 - method: GET - handler: PlansHandler29 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/30 - method: POST - handler: ProjectsHandler30 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/31 - method: GET - handler: ModelsHandler31 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/32 - method: GET - handler: AuthenticationHandler32 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/33 - method: POST - handler: PlansHandler33 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/34 - method: GET - handler: ProjectsHandler34 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/35 - method: GET - handler: ModelsHandler35 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/36 - method: POST - handler: AuthenticationHandler36 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/37 - method: GET - handler: PlansHandler37 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/38 - method: GET - handler: ProjectsHandler38 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/39 - method: POST - handler: ModelsHandler39 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/40 - method: GET - handler: AuthenticationHandler40 - is_streaming: true - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/41 - method: GET - handler: PlansHandler41 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/42 - method: POST - handler: ProjectsHandler42 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/43 - method: GET - handler: ModelsHandler43 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/44 - method: GET - handler: AuthenticationHandler44 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/{planId}/45 - method: POST - handler: PlansHandler45 - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans -- path: /api/projects/{projectId}/46 - method: GET - handler: ProjectsHandler46 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/47 - method: GET - handler: ModelsHandler47 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/48 - method: POST - handler: AuthenticationHandler48 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/49 - method: GET - handler: PlansHandler49 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/50 - method: GET - handler: ProjectsHandler50 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/51 - method: POST - handler: ModelsHandler51 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/52 - method: GET - handler: AuthenticationHandler52 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/53 - method: GET - handler: PlansHandler53 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/54 - method: POST - handler: ProjectsHandler54 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/55 - method: GET - handler: ModelsHandler55 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/56 - method: GET - handler: AuthenticationHandler56 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/57 - method: POST - handler: PlansHandler57 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/58 - method: GET - handler: ProjectsHandler58 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/59 - method: GET - handler: ModelsHandler59 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/60 - method: POST - handler: AuthenticationHandler60 - is_streaming: true - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/61 - method: GET - handler: PlansHandler61 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/62 - method: GET - handler: ProjectsHandler62 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/63 - method: POST - handler: ModelsHandler63 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/64 - method: GET - handler: AuthenticationHandler64 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/{planId}/65 - method: GET - handler: PlansHandler65 - is_streaming: false - requires_auth: true - path_params: - - projectId - - planId - description: '' - category: Plans -- path: /api/projects/{projectId}/66 - method: POST - handler: ProjectsHandler66 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/67 - method: GET - handler: ModelsHandler67 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/68 - method: GET - handler: AuthenticationHandler68 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/69 - method: POST - handler: PlansHandler69 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/70 - method: GET - handler: ProjectsHandler70 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/71 - method: GET - handler: ModelsHandler71 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models -- path: /api/authentication/72 - method: POST - handler: AuthenticationHandler72 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Authentication -- path: /api/plans/{projectId}/73 - method: GET - handler: PlansHandler73 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Plans -- path: /api/projects/{projectId}/74 - method: GET - handler: ProjectsHandler74 - is_streaming: false - requires_auth: true - path_params: - - projectId - description: '' - category: Projects -- path: /api/models/75 - method: POST - handler: ModelsHandler75 - is_streaming: false - requires_auth: true - path_params: [] - description: '' - category: Models diff --git a/docs/reference/shell_assets.json b/docs/reference/shell_assets.json deleted file mode 100644 index 447c6d0bc..000000000 --- a/docs/reference/shell_assets.json +++ /dev/null @@ -1,2277 +0,0 @@ -{ - "scripts": [ - { - "path": "app/clear_local.sh", - "name": "clear_local.sh", - "description": "Get the absolute path to the script's directory, regardless of where it's run from", - "dependencies": [], - "environment_vars": [ - "SCRIPT_DIR", - "REPLY", - "BASH_SOURCE" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "action", - "all", - "and", - "app", - "bash", - "be", - "containers", - "directories", - "dirname", - "docker", - "down", - "local", - "not", - "path", - "read", - "regardless", - "remove", - "removing", - "run", - "server", - "the", - "there", - "to", - "where", - "will", - "you" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": true, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/reset_local.sh", - "name": "reset_local.sh", - "description": "Get the absolute path to the script's directory, regardless of where it's run from", - "dependencies": [], - "environment_vars": [ - "SCRIPT_DIR", - "BASH_SOURCE" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "app", - "bash", - "dirname", - "local", - "not", - "path", - "regardless", - "run", - "the", - "there", - "to", - "where" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/start_local.sh", - "name": "start_local.sh", - "description": "Start local development environment with Docker", - "dependencies": [], - "environment_vars": [ - "SCRIPT_DIR", - "BASH_SOURCE" - ], - "inputs": [ - "Docker compose configuration", - "Docker compose configuration" - ], - "outputs": [ - "Running containers", - "Running containers" - ], - "side_effects": [ - "Starts Docker containers", - "Opens network ports", - "Starts Docker containers", - "Opens network ports" - ], - "commands_used": [ - "app", - "bash", - "before", - "dirname", - "docker", - "docker-compose", - "git", - "install", - "not", - "path", - "pull", - "regardless", - "run", - "server", - "the", - "there", - "this", - "to", - "up", - "where" - ], - "functions_defined": [], - "idempotent": true, - "requires_docker": true, - "requires_git": true, - "python_replacement_suggested": true - }, - { - "path": "app/cli/dev.sh", - "name": "dev.sh", - "description": "Development environment setup or commands", - "dependencies": [], - "environment_vars": [ - "PLANDEX_DEV_CLI_NAME", - "PLANDEX_DEV_CLI_ALIAS", - "OUT", - "PLANDEX_DEV_CLI_OUT_DIR", - "ALIAS", - "NAME" - ], - "inputs": [], - "outputs": [], - "side_effects": [ - "Modifies development environment", - "Modifies development environment" - ], - "commands_used": [ - "added", - "alias", - "and", - "bash", - "cli", - "cp", - "go", - "ln", - "prevent", - "quote", - "rm" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/cli/install.sh", - "name": "install.sh", - "description": "Set platform", - "dependencies": [], - "environment_vars": [ - "BIN_DIR", - "UID", - "LOC", - "PLATFORM", - "ENCODED_TAG", - "ARCH", - "PLANDEX_VERSION", - "BASH_SOURCE", - "VERSION", - "SCRIPT_DIR", - "RELEASES_URL", - "IS_DOCKER" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "able", - "alias", - "and", - "arch", - "as", - "attempt", - "attempting", - "bash", - "be", - "before", - "binary", - "builders", - "but", - "check_existing_installation", - "cleanup", - "community", - "complete", - "create", - "created", - "curl", - "custom", - "denied", - "directory", - "dirname", - "does", - "download_plandex", - "existing", - "grep", - "in", - "installation", - "is", - "it", - "ln", - "manually", - "may", - "mkdir", - "move", - "mv", - "not", - "now", - "of", - "on", - "or", - "overwrite", - "pdx", - "pdx1", - "plandex", - "plandex1", - "plandex_install_tmp", - "platform", - "project", - "prompt", - "rm", - "root", - "script", - "specific", - "starts", - "sudo", - "supported", - "tar", - "the", - "this", - "to", - "tr", - "trap", - "true", - "using", - "version", - "wc", - "we", - "welcome_plandex", - "with", - "work", - "your" - ], - "functions_defined": [ - "cleanup", - "welcome_plandex", - "download_plandex", - "check_existing_installation" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/scripts/dev.sh", - "name": "dev.sh", - "description": "Development environment setup or commands", - "dependencies": [], - "environment_vars": [ - "GOPATH", - "ZSH_VERSION", - "BASH_SOURCE", - "SCRIPT_DIR", - "PATH" - ], - "inputs": [], - "outputs": [], - "side_effects": [ - "Modifies development environment", - "Modifies development environment" - ], - "commands_used": [ - "and", - "bash", - "cli", - "deps", - "go", - "is", - "it", - "kill", - "not", - "of", - "pkill", - "plandex-server", - "process", - "reflex", - "script", - "server", - "sh", - "shell", - "the", - "to", - "trap", - "trigger", - "venv", - "wait", - "zsh" - ], - "functions_defined": [ - "terminate" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/scripts/litellm_deps.sh", - "name": "litellm_deps.sh", - "description": "", - "dependencies": [], - "environment_vars": [ - "VENV_DIR", - "REQUIRED_PYTHON", - "REQUIRED_PACKAGES", - "BASH_SOURCE", - "SCRIPT_DIR" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "already", - "and", - "at", - "bash", - "command", - "deactivate", - "in", - "install", - "is_installed", - "not", - "package", - "pip", - "python", - "this", - "venv", - "virtual" - ], - "functions_defined": [ - "is_installed" - ], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/scripts/wait-for-it.sh", - "name": "wait-for-it.sh", - "description": "Wait for a service to be available", - "dependencies": [], - "environment_vars": [ - "WAITFORIT_RESULT", - "WAITFORIT_PORT", - "WAITFORIT_", - "WAITFORIT_PID", - "WAITFORIT_QUIET", - "WAITFORIT_BUSYTIMEFLAG", - "WAITFORIT_CHILD", - "WAITFORIT_CLI", - "WAITFORIT_TIMEOUT_PATH", - "WAITFORIT_STRICT", - "WAITFORIT_ISBUSY", - "WAITFORIT_HOST", - "WAITFORIT_TIMEOUT" - ], - "inputs": [ - "Host and port to check", - "Host and port to check" - ], - "outputs": [ - "Exit code indicating availability", - "Exit code indicating availability" - ], - "side_effects": [], - "commands_used": [ - "after", - "and", - "are", - "args", - "as", - "bash", - "break", - "cat", - "command", - "during", - "echoerr", - "exec", - "execute", - "finishes", - "flag", - "given", - "grep", - "host", - "in", - "is", - "nc", - "no", - "or", - "order", - "output", - "port", - "process", - "readlink", - "refusing", - "seconds", - "sleep", - "status", - "strict", - "support", - "test", - "the", - "this", - "timeout", - "to", - "trap", - "under", - "usage", - "versions", - "wait", - "wait_for", - "wait_for_wrapper", - "waiting", - "without", - "you", - "zero" - ], - "functions_defined": [ - "echoerr", - "usage", - "wait_for", - "wait_for_wrapper" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/server/syntax/file_map/examples/bash_example.sh", - "name": "bash_example.sh", - "description": "Global variables", - "dependencies": [], - "environment_vars": [ - "GLOBAL_VAR" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "array", - "associative", - "declaration", - "declare", - "definition", - "in", - "is", - "local", - "main", - "print_message", - "readonly", - "script", - "through", - "value", - "variables", - "with", - "years" - ], - "functions_defined": [ - "print_message", - "get_date", - "main" - ], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/_test_apply.sh", - "name": "_test_apply.sh", - "description": "Check if python3 is available", - "dependencies": [], - "environment_vars": [ - "SERVER_PID" - ], - "inputs": [ - "Test project directory", - "Test project directory" - ], - "outputs": [ - "Test results", - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts", - "Creates/modifies test artifacts" - ], - "commands_used": [ - "application", - "browser", - "command", - "install", - "is", - "kill", - "moment", - "pipefail", - "plandex-dev", - "port", - "python", - "python3", - "server", - "simple", - "sleep", - "start", - "the", - "to", - "wait" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/plan_deletion_test.sh", - "name": "plan_deletion_test.sh", - "description": "Plandex hasn't been able to get this working yet", - "dependencies": [], - "environment_vars": [], - "inputs": [ - "Test project directory", - "Test project directory" - ], - "outputs": [ - "Test results", - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts", - "Creates/modifies test artifacts" - ], - "commands_used": [ - "all", - "been", - "but", - "check", - "check_plan_exists", - "complete", - "count", - "created", - "creation", - "debug", - "delete", - "deletion", - "ensure", - "existing", - "grep", - "head", - "in", - "initial", - "list", - "local", - "more", - "only", - "pdxd", - "plan", - "plans", - "range", - "remaining", - "sed", - "should", - "skip", - "sleep", - "starting", - "tail", - "test", - "tests", - "text", - "this", - "to", - "true", - "up", - "updated", - "was", - "wc", - "were", - "wildcard", - "with", - "worked", - "yet" - ], - "functions_defined": [ - "check_plan_exists", - "count_plans" - ], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/smoke_test.sh", - "name": "smoke_test.sh", - "description": "Plandex Smoke Test Script", - "dependencies": [], - "environment_vars": [ - "REWIND_STEPS", - "PROMPT_CREATE_FUNCTION", - "PROMPT_CHAT_QUESTION", - "PROMPT_ADD_TEST", - "PROMPT_ADD_FEATURE", - "BASH_SOURCE", - "SCRIPT_DIR" - ], - "inputs": [ - "Test project directory", - "Test project directory" - ], - "outputs": [ - "Test results", - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts", - "Creates/modifies test artifacts" - ], - "commands_used": [ - "all", - "and", - "another", - "archived", - "as", - "at", - "auto-continue", - "back", - "between", - "branch", - "branches", - "cat", - "changes", - "cheap", - "check_file", - "cleanup", - "cmd", - "code", - "command", - "common", - "context", - "conversation", - "core", - "current", - "diff", - "directory", - "does", - "feature", - "feature-branch", - "file", - "goodbye", - "has", - "have", - "hello", - "in", - "info", - "intentional", - "interact", - "is", - "it", - "linear", - "log", - "main", - "mimicking", - "mkdir", - "model", - "models", - "named", - "new", - "of", - "on", - "or", - "outdated", - "outside", - "pack", - "pending", - "plan", - "plans", - "project", - "rewind", - "run_plandex_cmd", - "second-plan", - "setting", - "setup", - "setup_test_dir", - "signed", - "simple", - "single", - "skip-changes-menu", - "smoke", - "so", - "specific", - "tell", - "test", - "that", - "the", - "to", - "trap", - "updated", - "usage", - "variables", - "with", - "without", - "world" - ], - "functions_defined": [ - "setup", - "main" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/test_custom_models.sh", - "name": "test_custom_models.sh", - "description": "custom-models-test.sh - Plandex custom models functionality test", - "dependencies": [], - "environment_vars": [ - "SCRIPT_DIR", - "PREV_KEY", - "BASH_SOURCE", - "OPENROUTER_API_KEY" - ], - "inputs": [ - "Test project directory", - "Test project directory" - ], - "outputs": [ - "Test results", - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts", - "Creates/modifies test artifacts" - ], - "commands_used": [ - "at", - "available", - "cat", - "cleanup", - "common", - "create_custom_models_json", - "current", - "custom", - "expect_plandex_failure", - "fail", - "file", - "functionality", - "hello", - "issue", - "key", - "log", - "main", - "matching", - "model", - "models", - "on", - "program", - "required", - "restore", - "run_plandex_cmd", - "setup", - "setup_test_dir", - "simple", - "test", - "the", - "to", - "trap", - "unset", - "with" - ], - "functions_defined": [ - "setup", - "create_custom_models_json", - "main" - ], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/test_utils.sh", - "name": "test_utils.sh", - "description": "test-utils.sh - Common utilities for Plandex test scripts", - "dependencies": [], - "environment_vars": [ - "RED", - "PLANDEX_CMD", - "TEST_DIR", - "GREEN", - "YELLOW", - "NC" - ], - "inputs": [ - "Test project directory", - "Test project directory" - ], - "outputs": [ - "Test results", - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts", - "Creates/modifies test artifacts" - ], - "commands_used": [ - "and", - "as", - "both", - "capture", - "check", - "code", - "command", - "contains", - "disable", - "environment", - "error", - "exists", - "expect_failure", - "expected", - "failed", - "fails", - "find", - "functions", - "grep", - "info", - "local", - "log", - "mkdir", - "on", - "plandex", - "rm", - "run_cmd", - "should", - "succeeded", - "success", - "test", - "the", - "to", - "up", - "utilities", - "with" - ], - "functions_defined": [ - "log", - "success", - "error", - "info", - "run_cmd", - "run_plandex_cmd", - "check_plandex_contains", - "expect_failure", - "expect_plandex_failure", - "check_file", - "setup_test_dir", - "cleanup_test_dir" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/pong/install_dependencies.sh", - "name": "install_dependencies.sh", - "description": "Check for Homebrew and install if not found", - "dependencies": [], - "environment_vars": [], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "and", - "brew", - "command", - "found", - "freeglut", - "installed", - "necessary", - "not" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "scripts/merge_from_reflog.sh", - "name": "merge_from_reflog.sh", - "description": "Check if the correct number of arguments are provided", - "dependencies": [], - "environment_vars": [], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "added", - "all", - "am", - "and", - "applied", - "applying", - "are", - "arguments", - "branch", - "cat", - "changes", - "commit", - "conflicts", - "correct", - "create", - "exists", - "file", - "files", - "find", - "following", - "from", - "git", - "hash", - "ls-files", - "merge", - "new", - "not", - "of", - "option", - "original", - "out", - "patch", - "patches", - "process", - "reflog", - "rejected", - "resolve", - "resolving", - "rm", - "run", - "specified", - "staged", - "the", - "three-way", - "to", - "touch", - "up", - "wc", - "with" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": true, - "python_replacement_suggested": false - }, - { - "path": "app/clear_local.sh", - "name": "clear_local.sh", - "description": "Get the absolute path to the script's directory, regardless of where it's run from", - "dependencies": [], - "environment_vars": [ - "SCRIPT_DIR", - "REPLY", - "BASH_SOURCE" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "action", - "all", - "and", - "app", - "bash", - "be", - "containers", - "directories", - "dirname", - "docker", - "down", - "local", - "not", - "path", - "read", - "regardless", - "remove", - "removing", - "run", - "server", - "the", - "there", - "to", - "where", - "will", - "you" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": true, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/reset_local.sh", - "name": "reset_local.sh", - "description": "Get the absolute path to the script's directory, regardless of where it's run from", - "dependencies": [], - "environment_vars": [ - "SCRIPT_DIR", - "BASH_SOURCE" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "app", - "bash", - "dirname", - "local", - "not", - "path", - "regardless", - "run", - "the", - "there", - "to", - "where" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/start_local.sh", - "name": "start_local.sh", - "description": "Start local development environment with Docker", - "dependencies": [], - "environment_vars": [ - "SCRIPT_DIR", - "BASH_SOURCE" - ], - "inputs": [ - "Docker compose configuration" - ], - "outputs": [ - "Running containers" - ], - "side_effects": [ - "Starts Docker containers", - "Opens network ports" - ], - "commands_used": [ - "app", - "bash", - "before", - "dirname", - "docker", - "docker-compose", - "git", - "install", - "not", - "path", - "pull", - "regardless", - "run", - "server", - "the", - "there", - "this", - "to", - "up", - "where" - ], - "functions_defined": [], - "idempotent": true, - "requires_docker": true, - "requires_git": true, - "python_replacement_suggested": true - }, - { - "path": "app/cli/dev.sh", - "name": "dev.sh", - "description": "Development environment setup or commands", - "dependencies": [], - "environment_vars": [ - "PLANDEX_DEV_CLI_NAME", - "PLANDEX_DEV_CLI_ALIAS", - "OUT", - "PLANDEX_DEV_CLI_OUT_DIR", - "ALIAS", - "NAME" - ], - "inputs": [], - "outputs": [], - "side_effects": [ - "Modifies development environment" - ], - "commands_used": [ - "added", - "alias", - "and", - "bash", - "cli", - "cp", - "go", - "ln", - "prevent", - "quote", - "rm" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/cli/install.sh", - "name": "install.sh", - "description": "Set platform", - "dependencies": [], - "environment_vars": [ - "BIN_DIR", - "UID", - "LOC", - "PLATFORM", - "ENCODED_TAG", - "ARCH", - "PLANDEX_VERSION", - "BASH_SOURCE", - "VERSION", - "SCRIPT_DIR", - "RELEASES_URL", - "IS_DOCKER" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "able", - "alias", - "and", - "arch", - "as", - "attempt", - "attempting", - "bash", - "be", - "before", - "binary", - "builders", - "but", - "check_existing_installation", - "cleanup", - "community", - "complete", - "create", - "created", - "curl", - "custom", - "denied", - "directory", - "dirname", - "does", - "download_plandex", - "existing", - "grep", - "in", - "installation", - "is", - "it", - "ln", - "manually", - "may", - "mkdir", - "move", - "mv", - "not", - "now", - "of", - "on", - "or", - "overwrite", - "pdx", - "pdx1", - "plandex", - "plandex1", - "plandex_install_tmp", - "platform", - "project", - "prompt", - "rm", - "root", - "script", - "specific", - "starts", - "sudo", - "supported", - "tar", - "the", - "this", - "to", - "tr", - "trap", - "true", - "using", - "version", - "wc", - "we", - "welcome_plandex", - "with", - "work", - "your" - ], - "functions_defined": [ - "cleanup", - "welcome_plandex", - "download_plandex", - "check_existing_installation" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/scripts/dev.sh", - "name": "dev.sh", - "description": "Development environment setup or commands", - "dependencies": [], - "environment_vars": [ - "GOPATH", - "ZSH_VERSION", - "BASH_SOURCE", - "SCRIPT_DIR", - "PATH" - ], - "inputs": [], - "outputs": [], - "side_effects": [ - "Modifies development environment" - ], - "commands_used": [ - "and", - "bash", - "cli", - "deps", - "go", - "is", - "it", - "kill", - "not", - "of", - "pkill", - "plandex-server", - "process", - "reflex", - "script", - "server", - "sh", - "shell", - "the", - "to", - "trap", - "trigger", - "venv", - "wait", - "zsh" - ], - "functions_defined": [ - "terminate" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/scripts/litellm_deps.sh", - "name": "litellm_deps.sh", - "description": "", - "dependencies": [], - "environment_vars": [ - "VENV_DIR", - "REQUIRED_PYTHON", - "REQUIRED_PACKAGES", - "BASH_SOURCE", - "SCRIPT_DIR" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "already", - "and", - "at", - "bash", - "command", - "deactivate", - "in", - "install", - "is_installed", - "not", - "package", - "pip", - "python", - "this", - "venv", - "virtual" - ], - "functions_defined": [ - "is_installed" - ], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/scripts/wait-for-it.sh", - "name": "wait-for-it.sh", - "description": "Wait for a service to be available", - "dependencies": [], - "environment_vars": [ - "WAITFORIT_RESULT", - "WAITFORIT_PORT", - "WAITFORIT_", - "WAITFORIT_PID", - "WAITFORIT_QUIET", - "WAITFORIT_BUSYTIMEFLAG", - "WAITFORIT_CHILD", - "WAITFORIT_CLI", - "WAITFORIT_TIMEOUT_PATH", - "WAITFORIT_STRICT", - "WAITFORIT_ISBUSY", - "WAITFORIT_HOST", - "WAITFORIT_TIMEOUT" - ], - "inputs": [ - "Host and port to check" - ], - "outputs": [ - "Exit code indicating availability" - ], - "side_effects": [], - "commands_used": [ - "after", - "and", - "are", - "args", - "as", - "bash", - "break", - "cat", - "command", - "during", - "echoerr", - "exec", - "execute", - "finishes", - "flag", - "given", - "grep", - "host", - "in", - "is", - "nc", - "no", - "or", - "order", - "output", - "port", - "process", - "readlink", - "refusing", - "seconds", - "sleep", - "status", - "strict", - "support", - "test", - "the", - "this", - "timeout", - "to", - "trap", - "under", - "usage", - "versions", - "wait", - "wait_for", - "wait_for_wrapper", - "waiting", - "without", - "you", - "zero" - ], - "functions_defined": [ - "echoerr", - "usage", - "wait_for", - "wait_for_wrapper" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "app/server/syntax/file_map/examples/bash_example.sh", - "name": "bash_example.sh", - "description": "Global variables", - "dependencies": [], - "environment_vars": [ - "GLOBAL_VAR" - ], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "array", - "associative", - "declaration", - "declare", - "definition", - "in", - "is", - "local", - "main", - "print_message", - "readonly", - "script", - "through", - "value", - "variables", - "with", - "years" - ], - "functions_defined": [ - "print_message", - "get_date", - "main" - ], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/_test_apply.sh", - "name": "_test_apply.sh", - "description": "Check if python3 is available", - "dependencies": [], - "environment_vars": [ - "SERVER_PID" - ], - "inputs": [ - "Test project directory" - ], - "outputs": [ - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts" - ], - "commands_used": [ - "application", - "browser", - "command", - "install", - "is", - "kill", - "moment", - "pipefail", - "plandex-dev", - "port", - "python", - "python3", - "server", - "simple", - "sleep", - "start", - "the", - "to", - "wait" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/plan_deletion_test.sh", - "name": "plan_deletion_test.sh", - "description": "Plandex hasn't been able to get this working yet", - "dependencies": [], - "environment_vars": [], - "inputs": [ - "Test project directory" - ], - "outputs": [ - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts" - ], - "commands_used": [ - "all", - "been", - "but", - "check", - "check_plan_exists", - "complete", - "count", - "created", - "creation", - "debug", - "delete", - "deletion", - "ensure", - "existing", - "grep", - "head", - "in", - "initial", - "list", - "local", - "more", - "only", - "pdxd", - "plan", - "plans", - "range", - "remaining", - "sed", - "should", - "skip", - "sleep", - "starting", - "tail", - "test", - "tests", - "text", - "this", - "to", - "true", - "up", - "updated", - "was", - "wc", - "were", - "wildcard", - "with", - "worked", - "yet" - ], - "functions_defined": [ - "check_plan_exists", - "count_plans" - ], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/smoke_test.sh", - "name": "smoke_test.sh", - "description": "Plandex Smoke Test Script", - "dependencies": [], - "environment_vars": [ - "REWIND_STEPS", - "PROMPT_CREATE_FUNCTION", - "PROMPT_CHAT_QUESTION", - "PROMPT_ADD_TEST", - "PROMPT_ADD_FEATURE", - "BASH_SOURCE", - "SCRIPT_DIR" - ], - "inputs": [ - "Test project directory" - ], - "outputs": [ - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts" - ], - "commands_used": [ - "all", - "and", - "another", - "archived", - "as", - "at", - "auto-continue", - "back", - "between", - "branch", - "branches", - "cat", - "changes", - "cheap", - "check_file", - "cleanup", - "cmd", - "code", - "command", - "common", - "context", - "conversation", - "core", - "current", - "diff", - "directory", - "does", - "feature", - "feature-branch", - "file", - "goodbye", - "has", - "have", - "hello", - "in", - "info", - "intentional", - "interact", - "is", - "it", - "linear", - "log", - "main", - "mimicking", - "mkdir", - "model", - "models", - "named", - "new", - "of", - "on", - "or", - "outdated", - "outside", - "pack", - "pending", - "plan", - "plans", - "project", - "rewind", - "run_plandex_cmd", - "second-plan", - "setting", - "setup", - "setup_test_dir", - "signed", - "simple", - "single", - "skip-changes-menu", - "smoke", - "so", - "specific", - "tell", - "test", - "that", - "the", - "to", - "trap", - "updated", - "usage", - "variables", - "with", - "without", - "world" - ], - "functions_defined": [ - "setup", - "main" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/test_custom_models.sh", - "name": "test_custom_models.sh", - "description": "custom-models-test.sh - Plandex custom models functionality test", - "dependencies": [], - "environment_vars": [ - "SCRIPT_DIR", - "PREV_KEY", - "BASH_SOURCE", - "OPENROUTER_API_KEY" - ], - "inputs": [ - "Test project directory" - ], - "outputs": [ - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts" - ], - "commands_used": [ - "at", - "available", - "cat", - "cleanup", - "common", - "create_custom_models_json", - "current", - "custom", - "expect_plandex_failure", - "fail", - "file", - "functionality", - "hello", - "issue", - "key", - "log", - "main", - "matching", - "model", - "models", - "on", - "program", - "required", - "restore", - "run_plandex_cmd", - "setup", - "setup_test_dir", - "simple", - "test", - "the", - "to", - "trap", - "unset", - "with" - ], - "functions_defined": [ - "setup", - "create_custom_models_json", - "main" - ], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/test_utils.sh", - "name": "test_utils.sh", - "description": "test-utils.sh - Common utilities for Plandex test scripts", - "dependencies": [], - "environment_vars": [ - "RED", - "PLANDEX_CMD", - "TEST_DIR", - "GREEN", - "YELLOW", - "NC" - ], - "inputs": [ - "Test project directory" - ], - "outputs": [ - "Test results" - ], - "side_effects": [ - "Creates/modifies test artifacts" - ], - "commands_used": [ - "and", - "as", - "both", - "capture", - "check", - "code", - "command", - "contains", - "disable", - "environment", - "error", - "exists", - "expect_failure", - "expected", - "failed", - "fails", - "find", - "functions", - "grep", - "info", - "local", - "log", - "mkdir", - "on", - "plandex", - "rm", - "run_cmd", - "should", - "succeeded", - "success", - "test", - "the", - "to", - "up", - "utilities", - "with" - ], - "functions_defined": [ - "log", - "success", - "error", - "info", - "run_cmd", - "run_plandex_cmd", - "check_plandex_contains", - "expect_failure", - "expect_plandex_failure", - "check_file", - "setup_test_dir", - "cleanup_test_dir" - ], - "idempotent": true, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "test/pong/install_dependencies.sh", - "name": "install_dependencies.sh", - "description": "Check for Homebrew and install if not found", - "dependencies": [], - "environment_vars": [], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "and", - "brew", - "command", - "found", - "freeglut", - "installed", - "necessary", - "not" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": false, - "python_replacement_suggested": false - }, - { - "path": "scripts/merge_from_reflog.sh", - "name": "merge_from_reflog.sh", - "description": "Check if the correct number of arguments are provided", - "dependencies": [], - "environment_vars": [], - "inputs": [], - "outputs": [], - "side_effects": [], - "commands_used": [ - "added", - "all", - "am", - "and", - "applied", - "applying", - "are", - "arguments", - "branch", - "cat", - "changes", - "commit", - "conflicts", - "correct", - "create", - "exists", - "file", - "files", - "find", - "following", - "from", - "git", - "hash", - "ls-files", - "merge", - "new", - "not", - "of", - "option", - "original", - "out", - "patch", - "patches", - "process", - "reflog", - "rejected", - "resolve", - "resolving", - "rm", - "run", - "specified", - "staged", - "the", - "three-way", - "to", - "touch", - "up", - "wc", - "with" - ], - "functions_defined": [], - "idempotent": false, - "requires_docker": false, - "requires_git": true, - "python_replacement_suggested": false - } - ], - "environment_map": { - "SCRIPT_DIR": [ - "app/clear_local.sh", - "app/reset_local.sh", - "app/start_local.sh", - "app/cli/install.sh", - "app/scripts/dev.sh", - "app/scripts/litellm_deps.sh", - "test/smoke_test.sh", - "test/test_custom_models.sh", - "app/clear_local.sh", - "app/reset_local.sh", - "app/start_local.sh", - "app/cli/install.sh", - "app/scripts/dev.sh", - "app/scripts/litellm_deps.sh", - "test/smoke_test.sh", - "test/test_custom_models.sh", - "app/clear_local.sh", - "app/reset_local.sh", - "app/start_local.sh", - "app/cli/install.sh", - "app/scripts/dev.sh", - "app/scripts/litellm_deps.sh", - "test/smoke_test.sh", - "test/test_custom_models.sh" - ], - "REPLY": [ - "app/clear_local.sh", - "app/clear_local.sh", - "app/clear_local.sh" - ], - "BASH_SOURCE": [ - "app/clear_local.sh", - "app/reset_local.sh", - "app/start_local.sh", - "app/cli/install.sh", - "app/scripts/dev.sh", - "app/scripts/litellm_deps.sh", - "test/smoke_test.sh", - "test/test_custom_models.sh", - "app/clear_local.sh", - "app/reset_local.sh", - "app/start_local.sh", - "app/cli/install.sh", - "app/scripts/dev.sh", - "app/scripts/litellm_deps.sh", - "test/smoke_test.sh", - "test/test_custom_models.sh", - "app/clear_local.sh", - "app/reset_local.sh", - "app/start_local.sh", - "app/cli/install.sh", - "app/scripts/dev.sh", - "app/scripts/litellm_deps.sh", - "test/smoke_test.sh", - "test/test_custom_models.sh" - ], - "PLANDEX_DEV_CLI_NAME": [ - "app/cli/dev.sh", - "app/cli/dev.sh", - "app/cli/dev.sh" - ], - "PLANDEX_DEV_CLI_ALIAS": [ - "app/cli/dev.sh", - "app/cli/dev.sh", - "app/cli/dev.sh" - ], - "OUT": [ - "app/cli/dev.sh", - "app/cli/dev.sh", - "app/cli/dev.sh" - ], - "PLANDEX_DEV_CLI_OUT_DIR": [ - "app/cli/dev.sh", - "app/cli/dev.sh", - "app/cli/dev.sh" - ], - "ALIAS": [ - "app/cli/dev.sh", - "app/cli/dev.sh", - "app/cli/dev.sh" - ], - "NAME": [ - "app/cli/dev.sh", - "app/cli/dev.sh", - "app/cli/dev.sh" - ], - "BIN_DIR": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "UID": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "LOC": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "PLATFORM": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "ENCODED_TAG": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "ARCH": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "PLANDEX_VERSION": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "VERSION": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "RELEASES_URL": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "IS_DOCKER": [ - "app/cli/install.sh", - "app/cli/install.sh", - "app/cli/install.sh" - ], - "GOPATH": [ - "app/scripts/dev.sh", - "app/scripts/dev.sh", - "app/scripts/dev.sh" - ], - "ZSH_VERSION": [ - "app/scripts/dev.sh", - "app/scripts/dev.sh", - "app/scripts/dev.sh" - ], - "PATH": [ - "app/scripts/dev.sh", - "app/scripts/dev.sh", - "app/scripts/dev.sh" - ], - "VENV_DIR": [ - "app/scripts/litellm_deps.sh", - "app/scripts/litellm_deps.sh", - "app/scripts/litellm_deps.sh" - ], - "REQUIRED_PYTHON": [ - "app/scripts/litellm_deps.sh", - "app/scripts/litellm_deps.sh", - "app/scripts/litellm_deps.sh" - ], - "REQUIRED_PACKAGES": [ - "app/scripts/litellm_deps.sh", - "app/scripts/litellm_deps.sh", - "app/scripts/litellm_deps.sh" - ], - "WAITFORIT_RESULT": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_PORT": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_PID": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_QUIET": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_BUSYTIMEFLAG": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_CHILD": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_CLI": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_TIMEOUT_PATH": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_STRICT": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_ISBUSY": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_HOST": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "WAITFORIT_TIMEOUT": [ - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh", - "app/scripts/wait-for-it.sh" - ], - "GLOBAL_VAR": [ - "app/server/syntax/file_map/examples/bash_example.sh", - "app/server/syntax/file_map/examples/bash_example.sh", - "app/server/syntax/file_map/examples/bash_example.sh" - ], - "SERVER_PID": [ - "test/_test_apply.sh", - "test/_test_apply.sh", - "test/_test_apply.sh" - ], - "REWIND_STEPS": [ - "test/smoke_test.sh", - "test/smoke_test.sh", - "test/smoke_test.sh" - ], - "PROMPT_CREATE_FUNCTION": [ - "test/smoke_test.sh", - "test/smoke_test.sh", - "test/smoke_test.sh" - ], - "PROMPT_CHAT_QUESTION": [ - "test/smoke_test.sh", - "test/smoke_test.sh", - "test/smoke_test.sh" - ], - "PROMPT_ADD_TEST": [ - "test/smoke_test.sh", - "test/smoke_test.sh", - "test/smoke_test.sh" - ], - "PROMPT_ADD_FEATURE": [ - "test/smoke_test.sh", - "test/smoke_test.sh", - "test/smoke_test.sh" - ], - "PREV_KEY": [ - "test/test_custom_models.sh", - "test/test_custom_models.sh", - "test/test_custom_models.sh" - ], - "OPENROUTER_API_KEY": [ - "test/test_custom_models.sh", - "test/test_custom_models.sh", - "test/test_custom_models.sh" - ], - "RED": [ - "test/test_utils.sh", - "test/test_utils.sh", - "test/test_utils.sh" - ], - "PLANDEX_CMD": [ - "test/test_utils.sh", - "test/test_utils.sh", - "test/test_utils.sh" - ], - "TEST_DIR": [ - "test/test_utils.sh", - "test/test_utils.sh", - "test/test_utils.sh" - ], - "GREEN": [ - "test/test_utils.sh", - "test/test_utils.sh", - "test/test_utils.sh" - ], - "YELLOW": [ - "test/test_utils.sh", - "test/test_utils.sh", - "test/test_utils.sh" - ], - "NC": [ - "test/test_utils.sh", - "test/test_utils.sh", - "test/test_utils.sh" - ] - }, - "statistics": { - "total_scripts": 32, - "docker_required": 4, - "git_required": 4, - "idempotent": 12, - "python_replacement": 2 - } -} \ No newline at end of file diff --git a/docs/reference/shell_assets.yaml b/docs/reference/shell_assets.yaml deleted file mode 100644 index 0cbbf53d1..000000000 --- a/docs/reference/shell_assets.yaml +++ /dev/null @@ -1,2039 +0,0 @@ -scripts: -- path: app/clear_local.sh - name: clear_local.sh - description: Get the absolute path to the script's directory, regardless of where - it's run from - dependencies: [] - environment_vars: - - SCRIPT_DIR - - REPLY - - BASH_SOURCE - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - action - - all - - and - - app - - bash - - be - - containers - - directories - - dirname - - docker - - down - - local - - not - - path - - read - - regardless - - remove - - removing - - run - - server - - the - - there - - to - - where - - will - - you - functions_defined: [] - idempotent: false - requires_docker: true - requires_git: false - python_replacement_suggested: false -- path: app/reset_local.sh - name: reset_local.sh - description: Get the absolute path to the script's directory, regardless of where - it's run from - dependencies: [] - environment_vars: - - SCRIPT_DIR - - BASH_SOURCE - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - app - - bash - - dirname - - local - - not - - path - - regardless - - run - - the - - there - - to - - where - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/start_local.sh - name: start_local.sh - description: Start local development environment with Docker - dependencies: [] - environment_vars: - - SCRIPT_DIR - - BASH_SOURCE - inputs: - - Docker compose configuration - - Docker compose configuration - outputs: - - Running containers - - Running containers - side_effects: - - Starts Docker containers - - Opens network ports - - Starts Docker containers - - Opens network ports - commands_used: - - app - - bash - - before - - dirname - - docker - - docker-compose - - git - - install - - not - - path - - pull - - regardless - - run - - server - - the - - there - - this - - to - - up - - where - functions_defined: [] - idempotent: true - requires_docker: true - requires_git: true - python_replacement_suggested: true -- path: app/cli/dev.sh - name: dev.sh - description: Development environment setup or commands - dependencies: [] - environment_vars: - - PLANDEX_DEV_CLI_NAME - - PLANDEX_DEV_CLI_ALIAS - - OUT - - PLANDEX_DEV_CLI_OUT_DIR - - ALIAS - - NAME - inputs: [] - outputs: [] - side_effects: - - Modifies development environment - - Modifies development environment - commands_used: - - added - - alias - - and - - bash - - cli - - cp - - go - - ln - - prevent - - quote - - rm - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/cli/install.sh - name: install.sh - description: Set platform - dependencies: [] - environment_vars: - - BIN_DIR - - UID - - LOC - - PLATFORM - - ENCODED_TAG - - ARCH - - PLANDEX_VERSION - - BASH_SOURCE - - VERSION - - SCRIPT_DIR - - RELEASES_URL - - IS_DOCKER - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - able - - alias - - and - - arch - - as - - attempt - - attempting - - bash - - be - - before - - binary - - builders - - but - - check_existing_installation - - cleanup - - community - - complete - - create - - created - - curl - - custom - - denied - - directory - - dirname - - does - - download_plandex - - existing - - grep - - in - - installation - - is - - it - - ln - - manually - - may - - mkdir - - move - - mv - - not - - now - - of - - 'on' - - or - - overwrite - - pdx - - pdx1 - - plandex - - plandex1 - - plandex_install_tmp - - platform - - project - - prompt - - rm - - root - - script - - specific - - starts - - sudo - - supported - - tar - - the - - this - - to - - tr - - trap - - 'true' - - using - - version - - wc - - we - - welcome_plandex - - with - - work - - your - functions_defined: - - cleanup - - welcome_plandex - - download_plandex - - check_existing_installation - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/scripts/dev.sh - name: dev.sh - description: Development environment setup or commands - dependencies: [] - environment_vars: - - GOPATH - - ZSH_VERSION - - BASH_SOURCE - - SCRIPT_DIR - - PATH - inputs: [] - outputs: [] - side_effects: - - Modifies development environment - - Modifies development environment - commands_used: - - and - - bash - - cli - - deps - - go - - is - - it - - kill - - not - - of - - pkill - - plandex-server - - process - - reflex - - script - - server - - sh - - shell - - the - - to - - trap - - trigger - - venv - - wait - - zsh - functions_defined: - - terminate - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/scripts/litellm_deps.sh - name: litellm_deps.sh - description: '' - dependencies: [] - environment_vars: - - VENV_DIR - - REQUIRED_PYTHON - - REQUIRED_PACKAGES - - BASH_SOURCE - - SCRIPT_DIR - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - already - - and - - at - - bash - - command - - deactivate - - in - - install - - is_installed - - not - - package - - pip - - python - - this - - venv - - virtual - functions_defined: - - is_installed - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/scripts/wait-for-it.sh - name: wait-for-it.sh - description: Wait for a service to be available - dependencies: [] - environment_vars: - - WAITFORIT_RESULT - - WAITFORIT_PORT - - WAITFORIT_ - - WAITFORIT_PID - - WAITFORIT_QUIET - - WAITFORIT_BUSYTIMEFLAG - - WAITFORIT_CHILD - - WAITFORIT_CLI - - WAITFORIT_TIMEOUT_PATH - - WAITFORIT_STRICT - - WAITFORIT_ISBUSY - - WAITFORIT_HOST - - WAITFORIT_TIMEOUT - inputs: - - Host and port to check - - Host and port to check - outputs: - - Exit code indicating availability - - Exit code indicating availability - side_effects: [] - commands_used: - - after - - and - - are - - args - - as - - bash - - break - - cat - - command - - during - - echoerr - - exec - - execute - - finishes - - flag - - given - - grep - - host - - in - - is - - nc - - 'no' - - or - - order - - output - - port - - process - - readlink - - refusing - - seconds - - sleep - - status - - strict - - support - - test - - the - - this - - timeout - - to - - trap - - under - - usage - - versions - - wait - - wait_for - - wait_for_wrapper - - waiting - - without - - you - - zero - functions_defined: - - echoerr - - usage - - wait_for - - wait_for_wrapper - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/server/syntax/file_map/examples/bash_example.sh - name: bash_example.sh - description: Global variables - dependencies: [] - environment_vars: - - GLOBAL_VAR - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - array - - associative - - declaration - - declare - - definition - - in - - is - - local - - main - - print_message - - readonly - - script - - through - - value - - variables - - with - - years - functions_defined: - - print_message - - get_date - - main - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/_test_apply.sh - name: _test_apply.sh - description: Check if python3 is available - dependencies: [] - environment_vars: - - SERVER_PID - inputs: - - Test project directory - - Test project directory - outputs: - - Test results - - Test results - side_effects: - - Creates/modifies test artifacts - - Creates/modifies test artifacts - commands_used: - - application - - browser - - command - - install - - is - - kill - - moment - - pipefail - - plandex-dev - - port - - python - - python3 - - server - - simple - - sleep - - start - - the - - to - - wait - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/plan_deletion_test.sh - name: plan_deletion_test.sh - description: Plandex hasn't been able to get this working yet - dependencies: [] - environment_vars: [] - inputs: - - Test project directory - - Test project directory - outputs: - - Test results - - Test results - side_effects: - - Creates/modifies test artifacts - - Creates/modifies test artifacts - commands_used: - - all - - been - - but - - check - - check_plan_exists - - complete - - count - - created - - creation - - debug - - delete - - deletion - - ensure - - existing - - grep - - head - - in - - initial - - list - - local - - more - - only - - pdxd - - plan - - plans - - range - - remaining - - sed - - should - - skip - - sleep - - starting - - tail - - test - - tests - - text - - this - - to - - 'true' - - up - - updated - - was - - wc - - were - - wildcard - - with - - worked - - yet - functions_defined: - - check_plan_exists - - count_plans - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/smoke_test.sh - name: smoke_test.sh - description: Plandex Smoke Test Script - dependencies: [] - environment_vars: - - REWIND_STEPS - - PROMPT_CREATE_FUNCTION - - PROMPT_CHAT_QUESTION - - PROMPT_ADD_TEST - - PROMPT_ADD_FEATURE - - BASH_SOURCE - - SCRIPT_DIR - inputs: - - Test project directory - - Test project directory - outputs: - - Test results - - Test results - side_effects: - - Creates/modifies test artifacts - - Creates/modifies test artifacts - commands_used: - - all - - and - - another - - archived - - as - - at - - auto-continue - - back - - between - - branch - - branches - - cat - - changes - - cheap - - check_file - - cleanup - - cmd - - code - - command - - common - - context - - conversation - - core - - current - - diff - - directory - - does - - feature - - feature-branch - - file - - goodbye - - has - - have - - hello - - in - - info - - intentional - - interact - - is - - it - - linear - - log - - main - - mimicking - - mkdir - - model - - models - - named - - new - - of - - 'on' - - or - - outdated - - outside - - pack - - pending - - plan - - plans - - project - - rewind - - run_plandex_cmd - - second-plan - - setting - - setup - - setup_test_dir - - signed - - simple - - single - - skip-changes-menu - - smoke - - so - - specific - - tell - - test - - that - - the - - to - - trap - - updated - - usage - - variables - - with - - without - - world - functions_defined: - - setup - - main - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/test_custom_models.sh - name: test_custom_models.sh - description: custom-models-test.sh - Plandex custom models functionality test - dependencies: [] - environment_vars: - - SCRIPT_DIR - - PREV_KEY - - BASH_SOURCE - - OPENROUTER_API_KEY - inputs: - - Test project directory - - Test project directory - outputs: - - Test results - - Test results - side_effects: - - Creates/modifies test artifacts - - Creates/modifies test artifacts - commands_used: - - at - - available - - cat - - cleanup - - common - - create_custom_models_json - - current - - custom - - expect_plandex_failure - - fail - - file - - functionality - - hello - - issue - - key - - log - - main - - matching - - model - - models - - 'on' - - program - - required - - restore - - run_plandex_cmd - - setup - - setup_test_dir - - simple - - test - - the - - to - - trap - - unset - - with - functions_defined: - - setup - - create_custom_models_json - - main - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/test_utils.sh - name: test_utils.sh - description: test-utils.sh - Common utilities for Plandex test scripts - dependencies: [] - environment_vars: - - RED - - PLANDEX_CMD - - TEST_DIR - - GREEN - - YELLOW - - NC - inputs: - - Test project directory - - Test project directory - outputs: - - Test results - - Test results - side_effects: - - Creates/modifies test artifacts - - Creates/modifies test artifacts - commands_used: - - and - - as - - both - - capture - - check - - code - - command - - contains - - disable - - environment - - error - - exists - - expect_failure - - expected - - failed - - fails - - find - - functions - - grep - - info - - local - - log - - mkdir - - 'on' - - plandex - - rm - - run_cmd - - should - - succeeded - - success - - test - - the - - to - - up - - utilities - - with - functions_defined: - - log - - success - - error - - info - - run_cmd - - run_plandex_cmd - - check_plandex_contains - - expect_failure - - expect_plandex_failure - - check_file - - setup_test_dir - - cleanup_test_dir - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/pong/install_dependencies.sh - name: install_dependencies.sh - description: Check for Homebrew and install if not found - dependencies: [] - environment_vars: [] - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - and - - brew - - command - - found - - freeglut - - installed - - necessary - - not - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: scripts/merge_from_reflog.sh - name: merge_from_reflog.sh - description: Check if the correct number of arguments are provided - dependencies: [] - environment_vars: [] - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - added - - all - - am - - and - - applied - - applying - - are - - arguments - - branch - - cat - - changes - - commit - - conflicts - - correct - - create - - exists - - file - - files - - find - - following - - from - - git - - hash - - ls-files - - merge - - new - - not - - of - - option - - original - - out - - patch - - patches - - process - - reflog - - rejected - - resolve - - resolving - - rm - - run - - specified - - staged - - the - - three-way - - to - - touch - - up - - wc - - with - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: true - python_replacement_suggested: false -- path: app/clear_local.sh - name: clear_local.sh - description: Get the absolute path to the script's directory, regardless of where - it's run from - dependencies: [] - environment_vars: - - SCRIPT_DIR - - REPLY - - BASH_SOURCE - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - action - - all - - and - - app - - bash - - be - - containers - - directories - - dirname - - docker - - down - - local - - not - - path - - read - - regardless - - remove - - removing - - run - - server - - the - - there - - to - - where - - will - - you - functions_defined: [] - idempotent: false - requires_docker: true - requires_git: false - python_replacement_suggested: false -- path: app/reset_local.sh - name: reset_local.sh - description: Get the absolute path to the script's directory, regardless of where - it's run from - dependencies: [] - environment_vars: - - SCRIPT_DIR - - BASH_SOURCE - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - app - - bash - - dirname - - local - - not - - path - - regardless - - run - - the - - there - - to - - where - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/start_local.sh - name: start_local.sh - description: Start local development environment with Docker - dependencies: [] - environment_vars: - - SCRIPT_DIR - - BASH_SOURCE - inputs: - - Docker compose configuration - outputs: - - Running containers - side_effects: - - Starts Docker containers - - Opens network ports - commands_used: - - app - - bash - - before - - dirname - - docker - - docker-compose - - git - - install - - not - - path - - pull - - regardless - - run - - server - - the - - there - - this - - to - - up - - where - functions_defined: [] - idempotent: true - requires_docker: true - requires_git: true - python_replacement_suggested: true -- path: app/cli/dev.sh - name: dev.sh - description: Development environment setup or commands - dependencies: [] - environment_vars: - - PLANDEX_DEV_CLI_NAME - - PLANDEX_DEV_CLI_ALIAS - - OUT - - PLANDEX_DEV_CLI_OUT_DIR - - ALIAS - - NAME - inputs: [] - outputs: [] - side_effects: - - Modifies development environment - commands_used: - - added - - alias - - and - - bash - - cli - - cp - - go - - ln - - prevent - - quote - - rm - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/cli/install.sh - name: install.sh - description: Set platform - dependencies: [] - environment_vars: - - BIN_DIR - - UID - - LOC - - PLATFORM - - ENCODED_TAG - - ARCH - - PLANDEX_VERSION - - BASH_SOURCE - - VERSION - - SCRIPT_DIR - - RELEASES_URL - - IS_DOCKER - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - able - - alias - - and - - arch - - as - - attempt - - attempting - - bash - - be - - before - - binary - - builders - - but - - check_existing_installation - - cleanup - - community - - complete - - create - - created - - curl - - custom - - denied - - directory - - dirname - - does - - download_plandex - - existing - - grep - - in - - installation - - is - - it - - ln - - manually - - may - - mkdir - - move - - mv - - not - - now - - of - - 'on' - - or - - overwrite - - pdx - - pdx1 - - plandex - - plandex1 - - plandex_install_tmp - - platform - - project - - prompt - - rm - - root - - script - - specific - - starts - - sudo - - supported - - tar - - the - - this - - to - - tr - - trap - - 'true' - - using - - version - - wc - - we - - welcome_plandex - - with - - work - - your - functions_defined: - - cleanup - - welcome_plandex - - download_plandex - - check_existing_installation - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/scripts/dev.sh - name: dev.sh - description: Development environment setup or commands - dependencies: [] - environment_vars: - - GOPATH - - ZSH_VERSION - - BASH_SOURCE - - SCRIPT_DIR - - PATH - inputs: [] - outputs: [] - side_effects: - - Modifies development environment - commands_used: - - and - - bash - - cli - - deps - - go - - is - - it - - kill - - not - - of - - pkill - - plandex-server - - process - - reflex - - script - - server - - sh - - shell - - the - - to - - trap - - trigger - - venv - - wait - - zsh - functions_defined: - - terminate - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/scripts/litellm_deps.sh - name: litellm_deps.sh - description: '' - dependencies: [] - environment_vars: - - VENV_DIR - - REQUIRED_PYTHON - - REQUIRED_PACKAGES - - BASH_SOURCE - - SCRIPT_DIR - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - already - - and - - at - - bash - - command - - deactivate - - in - - install - - is_installed - - not - - package - - pip - - python - - this - - venv - - virtual - functions_defined: - - is_installed - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/scripts/wait-for-it.sh - name: wait-for-it.sh - description: Wait for a service to be available - dependencies: [] - environment_vars: - - WAITFORIT_RESULT - - WAITFORIT_PORT - - WAITFORIT_ - - WAITFORIT_PID - - WAITFORIT_QUIET - - WAITFORIT_BUSYTIMEFLAG - - WAITFORIT_CHILD - - WAITFORIT_CLI - - WAITFORIT_TIMEOUT_PATH - - WAITFORIT_STRICT - - WAITFORIT_ISBUSY - - WAITFORIT_HOST - - WAITFORIT_TIMEOUT - inputs: - - Host and port to check - outputs: - - Exit code indicating availability - side_effects: [] - commands_used: - - after - - and - - are - - args - - as - - bash - - break - - cat - - command - - during - - echoerr - - exec - - execute - - finishes - - flag - - given - - grep - - host - - in - - is - - nc - - 'no' - - or - - order - - output - - port - - process - - readlink - - refusing - - seconds - - sleep - - status - - strict - - support - - test - - the - - this - - timeout - - to - - trap - - under - - usage - - versions - - wait - - wait_for - - wait_for_wrapper - - waiting - - without - - you - - zero - functions_defined: - - echoerr - - usage - - wait_for - - wait_for_wrapper - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: app/server/syntax/file_map/examples/bash_example.sh - name: bash_example.sh - description: Global variables - dependencies: [] - environment_vars: - - GLOBAL_VAR - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - array - - associative - - declaration - - declare - - definition - - in - - is - - local - - main - - print_message - - readonly - - script - - through - - value - - variables - - with - - years - functions_defined: - - print_message - - get_date - - main - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/_test_apply.sh - name: _test_apply.sh - description: Check if python3 is available - dependencies: [] - environment_vars: - - SERVER_PID - inputs: - - Test project directory - outputs: - - Test results - side_effects: - - Creates/modifies test artifacts - commands_used: - - application - - browser - - command - - install - - is - - kill - - moment - - pipefail - - plandex-dev - - port - - python - - python3 - - server - - simple - - sleep - - start - - the - - to - - wait - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/plan_deletion_test.sh - name: plan_deletion_test.sh - description: Plandex hasn't been able to get this working yet - dependencies: [] - environment_vars: [] - inputs: - - Test project directory - outputs: - - Test results - side_effects: - - Creates/modifies test artifacts - commands_used: - - all - - been - - but - - check - - check_plan_exists - - complete - - count - - created - - creation - - debug - - delete - - deletion - - ensure - - existing - - grep - - head - - in - - initial - - list - - local - - more - - only - - pdxd - - plan - - plans - - range - - remaining - - sed - - should - - skip - - sleep - - starting - - tail - - test - - tests - - text - - this - - to - - 'true' - - up - - updated - - was - - wc - - were - - wildcard - - with - - worked - - yet - functions_defined: - - check_plan_exists - - count_plans - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/smoke_test.sh - name: smoke_test.sh - description: Plandex Smoke Test Script - dependencies: [] - environment_vars: - - REWIND_STEPS - - PROMPT_CREATE_FUNCTION - - PROMPT_CHAT_QUESTION - - PROMPT_ADD_TEST - - PROMPT_ADD_FEATURE - - BASH_SOURCE - - SCRIPT_DIR - inputs: - - Test project directory - outputs: - - Test results - side_effects: - - Creates/modifies test artifacts - commands_used: - - all - - and - - another - - archived - - as - - at - - auto-continue - - back - - between - - branch - - branches - - cat - - changes - - cheap - - check_file - - cleanup - - cmd - - code - - command - - common - - context - - conversation - - core - - current - - diff - - directory - - does - - feature - - feature-branch - - file - - goodbye - - has - - have - - hello - - in - - info - - intentional - - interact - - is - - it - - linear - - log - - main - - mimicking - - mkdir - - model - - models - - named - - new - - of - - 'on' - - or - - outdated - - outside - - pack - - pending - - plan - - plans - - project - - rewind - - run_plandex_cmd - - second-plan - - setting - - setup - - setup_test_dir - - signed - - simple - - single - - skip-changes-menu - - smoke - - so - - specific - - tell - - test - - that - - the - - to - - trap - - updated - - usage - - variables - - with - - without - - world - functions_defined: - - setup - - main - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/test_custom_models.sh - name: test_custom_models.sh - description: custom-models-test.sh - Plandex custom models functionality test - dependencies: [] - environment_vars: - - SCRIPT_DIR - - PREV_KEY - - BASH_SOURCE - - OPENROUTER_API_KEY - inputs: - - Test project directory - outputs: - - Test results - side_effects: - - Creates/modifies test artifacts - commands_used: - - at - - available - - cat - - cleanup - - common - - create_custom_models_json - - current - - custom - - expect_plandex_failure - - fail - - file - - functionality - - hello - - issue - - key - - log - - main - - matching - - model - - models - - 'on' - - program - - required - - restore - - run_plandex_cmd - - setup - - setup_test_dir - - simple - - test - - the - - to - - trap - - unset - - with - functions_defined: - - setup - - create_custom_models_json - - main - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/test_utils.sh - name: test_utils.sh - description: test-utils.sh - Common utilities for Plandex test scripts - dependencies: [] - environment_vars: - - RED - - PLANDEX_CMD - - TEST_DIR - - GREEN - - YELLOW - - NC - inputs: - - Test project directory - outputs: - - Test results - side_effects: - - Creates/modifies test artifacts - commands_used: - - and - - as - - both - - capture - - check - - code - - command - - contains - - disable - - environment - - error - - exists - - expect_failure - - expected - - failed - - fails - - find - - functions - - grep - - info - - local - - log - - mkdir - - 'on' - - plandex - - rm - - run_cmd - - should - - succeeded - - success - - test - - the - - to - - up - - utilities - - with - functions_defined: - - log - - success - - error - - info - - run_cmd - - run_plandex_cmd - - check_plandex_contains - - expect_failure - - expect_plandex_failure - - check_file - - setup_test_dir - - cleanup_test_dir - idempotent: true - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: test/pong/install_dependencies.sh - name: install_dependencies.sh - description: Check for Homebrew and install if not found - dependencies: [] - environment_vars: [] - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - and - - brew - - command - - found - - freeglut - - installed - - necessary - - not - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: false - python_replacement_suggested: false -- path: scripts/merge_from_reflog.sh - name: merge_from_reflog.sh - description: Check if the correct number of arguments are provided - dependencies: [] - environment_vars: [] - inputs: [] - outputs: [] - side_effects: [] - commands_used: - - added - - all - - am - - and - - applied - - applying - - are - - arguments - - branch - - cat - - changes - - commit - - conflicts - - correct - - create - - exists - - file - - files - - find - - following - - from - - git - - hash - - ls-files - - merge - - new - - not - - of - - option - - original - - out - - patch - - patches - - process - - reflog - - rejected - - resolve - - resolving - - rm - - run - - specified - - staged - - the - - three-way - - to - - touch - - up - - wc - - with - functions_defined: [] - idempotent: false - requires_docker: false - requires_git: true - python_replacement_suggested: false -environment_map: - SCRIPT_DIR: - - app/clear_local.sh - - app/reset_local.sh - - app/start_local.sh - - app/cli/install.sh - - app/scripts/dev.sh - - app/scripts/litellm_deps.sh - - test/smoke_test.sh - - test/test_custom_models.sh - - app/clear_local.sh - - app/reset_local.sh - - app/start_local.sh - - app/cli/install.sh - - app/scripts/dev.sh - - app/scripts/litellm_deps.sh - - test/smoke_test.sh - - test/test_custom_models.sh - - app/clear_local.sh - - app/reset_local.sh - - app/start_local.sh - - app/cli/install.sh - - app/scripts/dev.sh - - app/scripts/litellm_deps.sh - - test/smoke_test.sh - - test/test_custom_models.sh - REPLY: - - app/clear_local.sh - - app/clear_local.sh - - app/clear_local.sh - BASH_SOURCE: - - app/clear_local.sh - - app/reset_local.sh - - app/start_local.sh - - app/cli/install.sh - - app/scripts/dev.sh - - app/scripts/litellm_deps.sh - - test/smoke_test.sh - - test/test_custom_models.sh - - app/clear_local.sh - - app/reset_local.sh - - app/start_local.sh - - app/cli/install.sh - - app/scripts/dev.sh - - app/scripts/litellm_deps.sh - - test/smoke_test.sh - - test/test_custom_models.sh - - app/clear_local.sh - - app/reset_local.sh - - app/start_local.sh - - app/cli/install.sh - - app/scripts/dev.sh - - app/scripts/litellm_deps.sh - - test/smoke_test.sh - - test/test_custom_models.sh - PLANDEX_DEV_CLI_NAME: - - app/cli/dev.sh - - app/cli/dev.sh - - app/cli/dev.sh - PLANDEX_DEV_CLI_ALIAS: - - app/cli/dev.sh - - app/cli/dev.sh - - app/cli/dev.sh - OUT: - - app/cli/dev.sh - - app/cli/dev.sh - - app/cli/dev.sh - PLANDEX_DEV_CLI_OUT_DIR: - - app/cli/dev.sh - - app/cli/dev.sh - - app/cli/dev.sh - ALIAS: - - app/cli/dev.sh - - app/cli/dev.sh - - app/cli/dev.sh - NAME: - - app/cli/dev.sh - - app/cli/dev.sh - - app/cli/dev.sh - BIN_DIR: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - UID: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - LOC: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - PLATFORM: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - ENCODED_TAG: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - ARCH: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - PLANDEX_VERSION: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - VERSION: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - RELEASES_URL: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - IS_DOCKER: - - app/cli/install.sh - - app/cli/install.sh - - app/cli/install.sh - GOPATH: - - app/scripts/dev.sh - - app/scripts/dev.sh - - app/scripts/dev.sh - ZSH_VERSION: - - app/scripts/dev.sh - - app/scripts/dev.sh - - app/scripts/dev.sh - PATH: - - app/scripts/dev.sh - - app/scripts/dev.sh - - app/scripts/dev.sh - VENV_DIR: - - app/scripts/litellm_deps.sh - - app/scripts/litellm_deps.sh - - app/scripts/litellm_deps.sh - REQUIRED_PYTHON: - - app/scripts/litellm_deps.sh - - app/scripts/litellm_deps.sh - - app/scripts/litellm_deps.sh - REQUIRED_PACKAGES: - - app/scripts/litellm_deps.sh - - app/scripts/litellm_deps.sh - - app/scripts/litellm_deps.sh - WAITFORIT_RESULT: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_PORT: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_PID: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_QUIET: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_BUSYTIMEFLAG: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_CHILD: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_CLI: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_TIMEOUT_PATH: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_STRICT: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_ISBUSY: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_HOST: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - WAITFORIT_TIMEOUT: - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - - app/scripts/wait-for-it.sh - GLOBAL_VAR: - - app/server/syntax/file_map/examples/bash_example.sh - - app/server/syntax/file_map/examples/bash_example.sh - - app/server/syntax/file_map/examples/bash_example.sh - SERVER_PID: - - test/_test_apply.sh - - test/_test_apply.sh - - test/_test_apply.sh - REWIND_STEPS: - - test/smoke_test.sh - - test/smoke_test.sh - - test/smoke_test.sh - PROMPT_CREATE_FUNCTION: - - test/smoke_test.sh - - test/smoke_test.sh - - test/smoke_test.sh - PROMPT_CHAT_QUESTION: - - test/smoke_test.sh - - test/smoke_test.sh - - test/smoke_test.sh - PROMPT_ADD_TEST: - - test/smoke_test.sh - - test/smoke_test.sh - - test/smoke_test.sh - PROMPT_ADD_FEATURE: - - test/smoke_test.sh - - test/smoke_test.sh - - test/smoke_test.sh - PREV_KEY: - - test/test_custom_models.sh - - test/test_custom_models.sh - - test/test_custom_models.sh - OPENROUTER_API_KEY: - - test/test_custom_models.sh - - test/test_custom_models.sh - - test/test_custom_models.sh - RED: - - test/test_utils.sh - - test/test_utils.sh - - test/test_utils.sh - PLANDEX_CMD: - - test/test_utils.sh - - test/test_utils.sh - - test/test_utils.sh - TEST_DIR: - - test/test_utils.sh - - test/test_utils.sh - - test/test_utils.sh - GREEN: - - test/test_utils.sh - - test/test_utils.sh - - test/test_utils.sh - YELLOW: - - test/test_utils.sh - - test/test_utils.sh - - test/test_utils.sh - NC: - - test/test_utils.sh - - test/test_utils.sh - - test/test_utils.sh -statistics: - total_scripts: 32 - docker_required: 4 - git_required: 4 - idempotent: 12 - python_replacement: 2 diff --git a/docs/reference/shell_wrappers/start_local.py b/docs/reference/shell_wrappers/start_local.py deleted file mode 100644 index b505453b8..000000000 --- a/docs/reference/shell_wrappers/start_local.py +++ /dev/null @@ -1,52 +0,0 @@ -"""Python wrapper for start_local.sh""" - -import os -import subprocess -from pathlib import Path - - -def run_start_local( - working_dir: str | None = None, - env: dict[str, str] | None = None, - capture_output: bool = True, - check: bool = True, -) -> subprocess.CompletedProcess: - """ - Run start_local.sh shell script. - - Original script: app/start_local.sh - Description: Start local development environment with Docker - Requires Docker: True - Requires Git: True - - Args: - working_dir: Directory to run the script in - env: Environment variables to set - capture_output: Whether to capture stdout/stderr - check: Whether to raise on non-zero exit code - - Returns: - CompletedProcess with the result - """ - script_path = ( - Path(__file__).parent.parent.parent.parent / "plandex" / "app/start_local.sh" - ) - - if not script_path.exists(): - raise FileNotFoundError(f"Script not found: {script_path}") - - # Merge environment variables - run_env = os.environ.copy() - if env: - run_env.update(env) - - # Required environment variables: SCRIPT_DIR, BASH_SOURCE - - return subprocess.run( - ["bash", str(script_path)], - cwd=working_dir, - env=run_env, - capture_output=capture_output, - check=check, - text=True, - ) diff --git a/docs/reference/workflows/workflow_parity.json b/docs/reference/workflows/workflow_parity.json deleted file mode 100644 index 1779024cc..000000000 --- a/docs/reference/workflows/workflow_parity.json +++ /dev/null @@ -1,1344 +0,0 @@ -{ - "workflows": { - "plan_create": { - "category": "plan_lifecycle", - "description": "Create a new plan with initial context", - "go_components": [ - "app/cli/cmd/plan.go", - "app/cli/cmd/new.go", - "app/cli/plan_exec/plan_exec.go", - "app/server/handlers/plan_handlers.go", - "app/server/db/plan_helpers.go" - ], - "stages": [ - { - "name": "initialization", - "description": "Create plan structure and metadata" - }, - { - "name": "context_setup", - "description": "Set up initial context and files" - }, - { - "name": "model_selection", - "description": "Choose default model for the plan" - }, - { - "name": "persistence", - "description": "Save plan to database/filesystem" - } - ], - "python_modules": [ - "cleveragents.domain.plans", - "cleveragents.application.plan_service", - "cleveragents.cli.commands.plan" - ], - "test_coverage": { - "behave": [ - "features/plans.feature" - ], - "robot": [ - "robot/plan_lifecycle.robot" - ], - "go_tests": [ - "app/cli/cmd/plan_test.go" - ] - }, - "dependencies": [ - "authentication", - "model_management", - "persistence" - ], - "notes": "Must maintain backward compatibility with existing plan formats" - }, - "plan_build": { - "category": "plan_lifecycle", - "description": "Build plan by processing prompts through AI models", - "go_components": [ - "app/cli/cmd/tell.go", - "app/cli/cmd/continue.go", - "app/cli/plan_exec/plan_build.go", - "app/server/handlers/build_handlers.go", - "app/shared/plan_build.go" - ], - "stages": [ - { - "name": "prompt_processing", - "description": "Process user prompts and context" - }, - { - "name": "model_interaction", - "description": "Send to AI model and get response" - }, - { - "name": "diff_generation", - "description": "Generate diffs from AI response" - }, - { - "name": "validation", - "description": "Validate generated changes" - }, - { - "name": "storage", - "description": "Store diffs and conversation history" - } - ], - "python_modules": [ - "cleveragents.application.build_service", - "cleveragents.domain.diffs", - "cleveragents.infrastructure.ai_providers", - "cleveragents.cli.commands.tell" - ], - "test_coverage": { - "behave": [ - "features/plan_build.feature" - ], - "robot": [ - "robot/build_workflow.robot" - ] - }, - "dependencies": [ - "model_management", - "diff_storage", - "streaming" - ], - "notes": "Streaming updates must match Go implementation timing" - }, - "plan_apply": { - "category": "plan_lifecycle", - "description": "Apply plan changes to files with review and confirmation", - "go_components": [ - "app/cli/cmd/apply.go", - "app/cli/plan_exec/apply_plan.go", - "app/server/handlers/apply_handlers.go", - "app/shared/apply.go" - ], - "stages": [ - { - "name": "diff_preview", - "description": "Show pending changes to user" - }, - { - "name": "confirmation", - "description": "Get user confirmation" - }, - { - "name": "file_updates", - "description": "Apply diffs to files" - }, - { - "name": "git_operations", - "description": "Optional git commit" - }, - { - "name": "cleanup", - "description": "Clean up temporary files" - } - ], - "python_modules": [ - "cleveragents.application.apply_service", - "cleveragents.domain.file_operations", - "cleveragents.infrastructure.git_integration", - "cleveragents.cli.commands.apply" - ], - "test_coverage": { - "behave": [ - "features/apply.feature" - ], - "robot": [ - "robot/apply_workflow.robot" - ] - }, - "dependencies": [ - "diff_management", - "file_operations", - "git_integration" - ], - "notes": "Must handle merge conflicts and rollback on failure" - }, - "context_load": { - "category": "context_management", - "description": "Load files and directories into plan context", - "go_components": [ - "app/cli/cmd/context.go", - "app/cli/cmd/load.go", - "app/cli/lib/context_loader.go", - "app/server/db/context_helpers.go" - ], - "stages": [ - { - "name": "path_resolution", - "description": "Resolve file paths and globs" - }, - { - "name": "content_reading", - "description": "Read file contents" - }, - { - "name": "filtering", - "description": "Apply ignore patterns" - }, - { - "name": "indexing", - "description": "Index content for search" - }, - { - "name": "storage", - "description": "Store in context database" - } - ], - "python_modules": [ - "cleveragents.domain.context", - "cleveragents.application.context_service", - "cleveragents.infrastructure.file_loader", - "cleveragents.cli.commands.context" - ], - "test_coverage": { - "behave": [ - "features/context.feature" - ], - "robot": [ - "robot/context_management.robot" - ] - }, - "dependencies": [ - "file_operations", - "path_resolution", - "indexing" - ], - "notes": "Auto-context detection must match Go heuristics" - }, - "context_auto": { - "category": "context_management", - "description": "Automatically detect and load relevant context", - "go_components": [ - "app/cli/lib/context_auto.go", - "app/cli/lib/context_heuristics.go" - ], - "stages": [ - { - "name": "detection", - "description": "Detect project type and structure" - }, - { - "name": "heuristics", - "description": "Apply loading heuristics" - }, - { - "name": "filtering", - "description": "Filter irrelevant files" - }, - { - "name": "loading", - "description": "Load detected context" - } - ], - "python_modules": [ - "cleveragents.application.auto_context", - "cleveragents.domain.heuristics" - ], - "test_coverage": { - "behave": [ - "features/auto_context.feature" - ], - "robot": [ - "robot/auto_context.robot" - ] - }, - "dependencies": [ - "context_load", - "project_detection" - ], - "notes": "Heuristics extracted in implicit behaviors discovery" - }, - "exec_command": { - "category": "execution_flows", - "description": "Execute commands in plan context with capture", - "go_components": [ - "app/cli/cmd/exec.go", - "app/cli/plan_exec/exec_cmd.go", - "app/shared/exec.go" - ], - "stages": [ - { - "name": "command_parsing", - "description": "Parse command and arguments" - }, - { - "name": "environment_setup", - "description": "Set up execution environment" - }, - { - "name": "execution", - "description": "Run command with output capture" - }, - { - "name": "result_processing", - "description": "Process output and errors" - }, - { - "name": "context_update", - "description": "Update context with results" - } - ], - "python_modules": [ - "cleveragents.application.exec_service", - "cleveragents.infrastructure.process_runner", - "cleveragents.domain.exec_results" - ], - "test_coverage": { - "behave": [ - "features/exec.feature" - ], - "robot": [ - "robot/execution.robot" - ] - }, - "dependencies": [ - "process_isolation", - "output_capture", - "context_management" - ], - "notes": "Must support process groups and cgroup isolation" - }, - "auto_debug": { - "category": "execution_flows", - "description": "Automatically debug and retry failed operations", - "go_components": [ - "app/cli/cmd/debug.go", - "app/cli/plan_exec/auto_debug.go", - "app/shared/debug.go" - ], - "stages": [ - { - "name": "error_detection", - "description": "Detect errors in output" - }, - { - "name": "error_analysis", - "description": "Analyze error for fix strategy" - }, - { - "name": "fix_generation", - "description": "Generate fix with AI model" - }, - { - "name": "fix_application", - "description": "Apply fix and retry" - }, - { - "name": "validation", - "description": "Validate fix succeeded" - } - ], - "python_modules": [ - "cleveragents.application.debug_service", - "cleveragents.domain.error_analysis", - "cleveragents.infrastructure.ai_debug" - ], - "test_coverage": { - "behave": [ - "features/auto_debug.feature" - ], - "robot": [ - "robot/debug_workflow.robot" - ] - }, - "dependencies": [ - "error_detection", - "model_interaction", - "retry_logic" - ], - "notes": "Retry limits and backoff must match Go implementation" - }, - "branch_create": { - "category": "branching", - "description": "Create and switch plan branches", - "go_components": [ - "app/cli/cmd/branches.go", - "app/cli/lib/branch_helpers.go", - "app/server/db/branch_helpers.go" - ], - "stages": [ - { - "name": "validation", - "description": "Validate branch name" - }, - { - "name": "creation", - "description": "Create branch structure" - }, - { - "name": "copying", - "description": "Copy current state to branch" - }, - { - "name": "switching", - "description": "Switch to new branch" - }, - { - "name": "persistence", - "description": "Save branch metadata" - } - ], - "python_modules": [ - "cleveragents.domain.branches", - "cleveragents.application.branch_service", - "cleveragents.cli.commands.branches" - ], - "test_coverage": { - "behave": [ - "features/branches.feature" - ], - "robot": [ - "robot/branching.robot" - ] - }, - "dependencies": [ - "plan_management", - "diff_storage", - "state_management" - ], - "notes": "Branch switching must preserve unsaved changes" - }, - "branch_merge": { - "category": "branching", - "description": "Merge branches with conflict resolution", - "go_components": [ - "app/cli/cmd/merge.go", - "app/cli/lib/merge_helpers.go" - ], - "stages": [ - { - "name": "diff_comparison", - "description": "Compare branch diffs" - }, - { - "name": "conflict_detection", - "description": "Detect merge conflicts" - }, - { - "name": "conflict_resolution", - "description": "Resolve conflicts" - }, - { - "name": "merge_application", - "description": "Apply merged changes" - }, - { - "name": "cleanup", - "description": "Clean up merged branch" - } - ], - "python_modules": [ - "cleveragents.application.merge_service", - "cleveragents.domain.conflict_resolution" - ], - "test_coverage": { - "behave": [ - "features/merge.feature" - ], - "robot": [ - "robot/merge_workflow.robot" - ] - }, - "dependencies": [ - "diff_management", - "conflict_detection", - "state_management" - ], - "notes": "Must support manual and automatic conflict resolution" - }, - "auth_login": { - "category": "authentication", - "description": "User authentication and session establishment", - "go_components": [ - "app/cli/cmd/sign_in.go", - "app/cli/lib/auth.go", - "app/server/handlers/auth_handlers.go", - "app/server/db/user_helpers.go" - ], - "stages": [ - { - "name": "credential_input", - "description": "Get user credentials" - }, - { - "name": "authentication", - "description": "Verify credentials" - }, - { - "name": "session_creation", - "description": "Create session token" - }, - { - "name": "token_storage", - "description": "Store token locally" - }, - { - "name": "verification", - "description": "Verify session active" - } - ], - "python_modules": [ - "cleveragents.infrastructure.auth", - "cleveragents.domain.sessions", - "cleveragents.cli.commands.auth" - ], - "test_coverage": { - "behave": [ - "features/authentication.feature" - ], - "robot": [ - "robot/auth_workflow.robot" - ] - }, - "dependencies": [ - "user_management", - "token_management", - "encryption" - ], - "notes": "Must support both API key and email/password auth" - }, - "model_selection": { - "category": "model_management", - "description": "Select and configure AI models", - "go_components": [ - "app/cli/cmd/models.go", - "app/cli/cmd/set_model.go", - "app/cli/lib/models_sync.go", - "app/shared/ai_models.go" - ], - "stages": [ - { - "name": "model_listing", - "description": "List available models" - }, - { - "name": "capability_check", - "description": "Check model capabilities" - }, - { - "name": "selection", - "description": "Select model" - }, - { - "name": "validation", - "description": "Validate API keys" - }, - { - "name": "configuration", - "description": "Save model configuration" - } - ], - "python_modules": [ - "cleveragents.domain.models", - "cleveragents.application.model_service", - "cleveragents.infrastructure.model_providers", - "cleveragents.cli.commands.models" - ], - "test_coverage": { - "behave": [ - "features/models.feature" - ], - "robot": [ - "robot/model_management.robot" - ] - }, - "dependencies": [ - "provider_integration", - "api_key_management", - "model_catalog" - ], - "notes": "Model catalog refresh must be automated" - }, - "config_management": { - "category": "configuration", - "description": "Manage application configuration", - "go_components": [ - "app/cli/cmd/config.go", - "app/cli/lib/config.go", - "app/server/config/config.go" - ], - "stages": [ - { - "name": "config_loading", - "description": "Load configuration files" - }, - { - "name": "env_merging", - "description": "Merge environment variables" - }, - { - "name": "validation", - "description": "Validate configuration" - }, - { - "name": "application", - "description": "Apply configuration" - }, - { - "name": "persistence", - "description": "Save configuration changes" - } - ], - "python_modules": [ - "cleveragents.infrastructure.config", - "cleveragents.domain.settings", - "cleveragents.cli.commands.config" - ], - "test_coverage": { - "behave": [ - "features/configuration.feature" - ], - "robot": [ - "robot/config_management.robot" - ] - }, - "dependencies": [ - "file_operations", - "env_variables", - "validation" - ], - "notes": "Must support CLEVERAGENTS_ env vars exclusively" - }, - "team_invite": { - "category": "collaboration", - "description": "Invite team members and manage permissions", - "go_components": [ - "app/cli/cmd/invite.go", - "app/server/handlers/invite_handlers.go", - "app/server/db/invite_helpers.go" - ], - "stages": [ - { - "name": "invite_creation", - "description": "Create invite" - }, - { - "name": "notification", - "description": "Send invite notification" - }, - { - "name": "acceptance", - "description": "Process invite acceptance" - }, - { - "name": "permission_grant", - "description": "Grant permissions" - }, - { - "name": "sync", - "description": "Sync team state" - } - ], - "python_modules": [ - "cleveragents.domain.teams", - "cleveragents.application.invite_service", - "cleveragents.infrastructure.notifications" - ], - "test_coverage": { - "behave": [ - "features/collaboration.feature" - ], - "robot": [ - "robot/team_workflow.robot" - ] - }, - "dependencies": [ - "user_management", - "permissions", - "notifications" - ], - "notes": "Replace cloud invites with SMTP or local alternatives" - }, - "stream_updates": { - "category": "streaming", - "description": "Stream real-time updates during operations", - "go_components": [ - "app/cli/stream_tui/stream_tui.go", - "app/cli/lib/active_stream.go", - "app/server/handlers/stream_handlers.go" - ], - "stages": [ - { - "name": "connection", - "description": "Establish streaming connection" - }, - { - "name": "buffering", - "description": "Buffer incoming chunks" - }, - { - "name": "rendering", - "description": "Render updates to UI" - }, - { - "name": "error_handling", - "description": "Handle connection errors" - }, - { - "name": "cleanup", - "description": "Clean up on completion" - } - ], - "python_modules": [ - "cleveragents.infrastructure.streaming", - "cleveragents.application.stream_service", - "cleveragents.cli.ui.stream_renderer" - ], - "test_coverage": { - "behave": [ - "features/streaming.feature" - ], - "robot": [ - "robot/streaming.robot" - ] - }, - "dependencies": [ - "websockets", - "ui_rendering", - "backpressure" - ], - "notes": "Must handle reconnection and backpressure" - }, - "background_jobs": { - "category": "background_jobs", - "description": "Manage background tasks and job scheduling", - "go_components": [ - "app/server/db/job_helpers.go", - "app/server/workers/workers.go", - "app/cli/lib/background_tasks.go" - ], - "stages": [ - { - "name": "job_creation", - "description": "Create job definition" - }, - { - "name": "scheduling", - "description": "Schedule job execution" - }, - { - "name": "execution", - "description": "Execute job task" - }, - { - "name": "retry", - "description": "Retry on failure" - }, - { - "name": "completion", - "description": "Mark job complete" - } - ], - "python_modules": [ - "cleveragents.infrastructure.jobs", - "cleveragents.application.job_service", - "cleveragents.domain.background_tasks" - ], - "test_coverage": { - "behave": [ - "features/background_jobs.feature" - ], - "robot": [ - "robot/job_scheduling.robot" - ] - }, - "dependencies": [ - "task_queue", - "retry_logic", - "scheduling" - ], - "notes": "Use asyncio or celery for job management" - } - }, - "matrix": { - "go_to_python": { - "app/cli/cmd/plan.go": [ - "cleveragents.domain.plans", - "cleveragents.application.plan_service", - "cleveragents.cli.commands.plan" - ], - "app/cli/cmd/new.go": [ - "cleveragents.domain.plans", - "cleveragents.application.plan_service", - "cleveragents.cli.commands.plan" - ], - "app/cli/plan_exec/plan_exec.go": [ - "cleveragents.domain.plans", - "cleveragents.application.plan_service", - "cleveragents.cli.commands.plan" - ], - "app/server/handlers/plan_handlers.go": [ - "cleveragents.domain.plans", - "cleveragents.application.plan_service", - "cleveragents.cli.commands.plan" - ], - "app/server/db/plan_helpers.go": [ - "cleveragents.domain.plans", - "cleveragents.application.plan_service", - "cleveragents.cli.commands.plan" - ], - "app/cli/cmd/tell.go": [ - "cleveragents.application.build_service", - "cleveragents.domain.diffs", - "cleveragents.infrastructure.ai_providers", - "cleveragents.cli.commands.tell" - ], - "app/cli/cmd/continue.go": [ - "cleveragents.application.build_service", - "cleveragents.domain.diffs", - "cleveragents.infrastructure.ai_providers", - "cleveragents.cli.commands.tell" - ], - "app/cli/plan_exec/plan_build.go": [ - "cleveragents.application.build_service", - "cleveragents.domain.diffs", - "cleveragents.infrastructure.ai_providers", - "cleveragents.cli.commands.tell" - ], - "app/server/handlers/build_handlers.go": [ - "cleveragents.application.build_service", - "cleveragents.domain.diffs", - "cleveragents.infrastructure.ai_providers", - "cleveragents.cli.commands.tell" - ], - "app/shared/plan_build.go": [ - "cleveragents.application.build_service", - "cleveragents.domain.diffs", - "cleveragents.infrastructure.ai_providers", - "cleveragents.cli.commands.tell" - ], - "app/cli/cmd/apply.go": [ - "cleveragents.application.apply_service", - "cleveragents.domain.file_operations", - "cleveragents.infrastructure.git_integration", - "cleveragents.cli.commands.apply" - ], - "app/cli/plan_exec/apply_plan.go": [ - "cleveragents.application.apply_service", - "cleveragents.domain.file_operations", - "cleveragents.infrastructure.git_integration", - "cleveragents.cli.commands.apply" - ], - "app/server/handlers/apply_handlers.go": [ - "cleveragents.application.apply_service", - "cleveragents.domain.file_operations", - "cleveragents.infrastructure.git_integration", - "cleveragents.cli.commands.apply" - ], - "app/shared/apply.go": [ - "cleveragents.application.apply_service", - "cleveragents.domain.file_operations", - "cleveragents.infrastructure.git_integration", - "cleveragents.cli.commands.apply" - ], - "app/cli/cmd/context.go": [ - "cleveragents.domain.context", - "cleveragents.application.context_service", - "cleveragents.infrastructure.file_loader", - "cleveragents.cli.commands.context" - ], - "app/cli/cmd/load.go": [ - "cleveragents.domain.context", - "cleveragents.application.context_service", - "cleveragents.infrastructure.file_loader", - "cleveragents.cli.commands.context" - ], - "app/cli/lib/context_loader.go": [ - "cleveragents.domain.context", - "cleveragents.application.context_service", - "cleveragents.infrastructure.file_loader", - "cleveragents.cli.commands.context" - ], - "app/server/db/context_helpers.go": [ - "cleveragents.domain.context", - "cleveragents.application.context_service", - "cleveragents.infrastructure.file_loader", - "cleveragents.cli.commands.context" - ], - "app/cli/lib/context_auto.go": [ - "cleveragents.application.auto_context", - "cleveragents.domain.heuristics" - ], - "app/cli/lib/context_heuristics.go": [ - "cleveragents.application.auto_context", - "cleveragents.domain.heuristics" - ], - "app/cli/cmd/exec.go": [ - "cleveragents.application.exec_service", - "cleveragents.infrastructure.process_runner", - "cleveragents.domain.exec_results" - ], - "app/cli/plan_exec/exec_cmd.go": [ - "cleveragents.application.exec_service", - "cleveragents.infrastructure.process_runner", - "cleveragents.domain.exec_results" - ], - "app/shared/exec.go": [ - "cleveragents.application.exec_service", - "cleveragents.infrastructure.process_runner", - "cleveragents.domain.exec_results" - ], - "app/cli/cmd/debug.go": [ - "cleveragents.application.debug_service", - "cleveragents.domain.error_analysis", - "cleveragents.infrastructure.ai_debug" - ], - "app/cli/plan_exec/auto_debug.go": [ - "cleveragents.application.debug_service", - "cleveragents.domain.error_analysis", - "cleveragents.infrastructure.ai_debug" - ], - "app/shared/debug.go": [ - "cleveragents.application.debug_service", - "cleveragents.domain.error_analysis", - "cleveragents.infrastructure.ai_debug" - ], - "app/cli/cmd/branches.go": [ - "cleveragents.domain.branches", - "cleveragents.application.branch_service", - "cleveragents.cli.commands.branches" - ], - "app/cli/lib/branch_helpers.go": [ - "cleveragents.domain.branches", - "cleveragents.application.branch_service", - "cleveragents.cli.commands.branches" - ], - "app/server/db/branch_helpers.go": [ - "cleveragents.domain.branches", - "cleveragents.application.branch_service", - "cleveragents.cli.commands.branches" - ], - "app/cli/cmd/merge.go": [ - "cleveragents.application.merge_service", - "cleveragents.domain.conflict_resolution" - ], - "app/cli/lib/merge_helpers.go": [ - "cleveragents.application.merge_service", - "cleveragents.domain.conflict_resolution" - ], - "app/cli/cmd/sign_in.go": [ - "cleveragents.infrastructure.auth", - "cleveragents.domain.sessions", - "cleveragents.cli.commands.auth" - ], - "app/cli/lib/auth.go": [ - "cleveragents.infrastructure.auth", - "cleveragents.domain.sessions", - "cleveragents.cli.commands.auth" - ], - "app/server/handlers/auth_handlers.go": [ - "cleveragents.infrastructure.auth", - "cleveragents.domain.sessions", - "cleveragents.cli.commands.auth" - ], - "app/server/db/user_helpers.go": [ - "cleveragents.infrastructure.auth", - "cleveragents.domain.sessions", - "cleveragents.cli.commands.auth" - ], - "app/cli/cmd/models.go": [ - "cleveragents.domain.models", - "cleveragents.application.model_service", - "cleveragents.infrastructure.model_providers", - "cleveragents.cli.commands.models" - ], - "app/cli/cmd/set_model.go": [ - "cleveragents.domain.models", - "cleveragents.application.model_service", - "cleveragents.infrastructure.model_providers", - "cleveragents.cli.commands.models" - ], - "app/cli/lib/models_sync.go": [ - "cleveragents.domain.models", - "cleveragents.application.model_service", - "cleveragents.infrastructure.model_providers", - "cleveragents.cli.commands.models" - ], - "app/shared/ai_models.go": [ - "cleveragents.domain.models", - "cleveragents.application.model_service", - "cleveragents.infrastructure.model_providers", - "cleveragents.cli.commands.models" - ], - "app/cli/cmd/config.go": [ - "cleveragents.infrastructure.config", - "cleveragents.domain.settings", - "cleveragents.cli.commands.config" - ], - "app/cli/lib/config.go": [ - "cleveragents.infrastructure.config", - "cleveragents.domain.settings", - "cleveragents.cli.commands.config" - ], - "app/server/config/config.go": [ - "cleveragents.infrastructure.config", - "cleveragents.domain.settings", - "cleveragents.cli.commands.config" - ], - "app/cli/cmd/invite.go": [ - "cleveragents.domain.teams", - "cleveragents.application.invite_service", - "cleveragents.infrastructure.notifications" - ], - "app/server/handlers/invite_handlers.go": [ - "cleveragents.domain.teams", - "cleveragents.application.invite_service", - "cleveragents.infrastructure.notifications" - ], - "app/server/db/invite_helpers.go": [ - "cleveragents.domain.teams", - "cleveragents.application.invite_service", - "cleveragents.infrastructure.notifications" - ], - "app/cli/stream_tui/stream_tui.go": [ - "cleveragents.infrastructure.streaming", - "cleveragents.application.stream_service", - "cleveragents.cli.ui.stream_renderer" - ], - "app/cli/lib/active_stream.go": [ - "cleveragents.infrastructure.streaming", - "cleveragents.application.stream_service", - "cleveragents.cli.ui.stream_renderer" - ], - "app/server/handlers/stream_handlers.go": [ - "cleveragents.infrastructure.streaming", - "cleveragents.application.stream_service", - "cleveragents.cli.ui.stream_renderer" - ], - "app/server/db/job_helpers.go": [ - "cleveragents.infrastructure.jobs", - "cleveragents.application.job_service", - "cleveragents.domain.background_tasks" - ], - "app/server/workers/workers.go": [ - "cleveragents.infrastructure.jobs", - "cleveragents.application.job_service", - "cleveragents.domain.background_tasks" - ], - "app/cli/lib/background_tasks.go": [ - "cleveragents.infrastructure.jobs", - "cleveragents.application.job_service", - "cleveragents.domain.background_tasks" - ] - }, - "python_to_go": { - "cleveragents.domain.plans": [ - "app/cli/cmd/plan.go", - "app/cli/cmd/new.go", - "app/cli/plan_exec/plan_exec.go", - "app/server/handlers/plan_handlers.go", - "app/server/db/plan_helpers.go" - ], - "cleveragents.application.plan_service": [ - "app/cli/cmd/plan.go", - "app/cli/cmd/new.go", - "app/cli/plan_exec/plan_exec.go", - "app/server/handlers/plan_handlers.go", - "app/server/db/plan_helpers.go" - ], - "cleveragents.cli.commands.plan": [ - "app/cli/cmd/plan.go", - "app/cli/cmd/new.go", - "app/cli/plan_exec/plan_exec.go", - "app/server/handlers/plan_handlers.go", - "app/server/db/plan_helpers.go" - ], - "cleveragents.application.build_service": [ - "app/cli/cmd/tell.go", - "app/cli/cmd/continue.go", - "app/cli/plan_exec/plan_build.go", - "app/server/handlers/build_handlers.go", - "app/shared/plan_build.go" - ], - "cleveragents.domain.diffs": [ - "app/cli/cmd/tell.go", - "app/cli/cmd/continue.go", - "app/cli/plan_exec/plan_build.go", - "app/server/handlers/build_handlers.go", - "app/shared/plan_build.go" - ], - "cleveragents.infrastructure.ai_providers": [ - "app/cli/cmd/tell.go", - "app/cli/cmd/continue.go", - "app/cli/plan_exec/plan_build.go", - "app/server/handlers/build_handlers.go", - "app/shared/plan_build.go" - ], - "cleveragents.cli.commands.tell": [ - "app/cli/cmd/tell.go", - "app/cli/cmd/continue.go", - "app/cli/plan_exec/plan_build.go", - "app/server/handlers/build_handlers.go", - "app/shared/plan_build.go" - ], - "cleveragents.application.apply_service": [ - "app/cli/cmd/apply.go", - "app/cli/plan_exec/apply_plan.go", - "app/server/handlers/apply_handlers.go", - "app/shared/apply.go" - ], - "cleveragents.domain.file_operations": [ - "app/cli/cmd/apply.go", - "app/cli/plan_exec/apply_plan.go", - "app/server/handlers/apply_handlers.go", - "app/shared/apply.go" - ], - "cleveragents.infrastructure.git_integration": [ - "app/cli/cmd/apply.go", - "app/cli/plan_exec/apply_plan.go", - "app/server/handlers/apply_handlers.go", - "app/shared/apply.go" - ], - "cleveragents.cli.commands.apply": [ - "app/cli/cmd/apply.go", - "app/cli/plan_exec/apply_plan.go", - "app/server/handlers/apply_handlers.go", - "app/shared/apply.go" - ], - "cleveragents.domain.context": [ - "app/cli/cmd/context.go", - "app/cli/cmd/load.go", - "app/cli/lib/context_loader.go", - "app/server/db/context_helpers.go" - ], - "cleveragents.application.context_service": [ - "app/cli/cmd/context.go", - "app/cli/cmd/load.go", - "app/cli/lib/context_loader.go", - "app/server/db/context_helpers.go" - ], - "cleveragents.infrastructure.file_loader": [ - "app/cli/cmd/context.go", - "app/cli/cmd/load.go", - "app/cli/lib/context_loader.go", - "app/server/db/context_helpers.go" - ], - "cleveragents.cli.commands.context": [ - "app/cli/cmd/context.go", - "app/cli/cmd/load.go", - "app/cli/lib/context_loader.go", - "app/server/db/context_helpers.go" - ], - "cleveragents.application.auto_context": [ - "app/cli/lib/context_auto.go", - "app/cli/lib/context_heuristics.go" - ], - "cleveragents.domain.heuristics": [ - "app/cli/lib/context_auto.go", - "app/cli/lib/context_heuristics.go" - ], - "cleveragents.application.exec_service": [ - "app/cli/cmd/exec.go", - "app/cli/plan_exec/exec_cmd.go", - "app/shared/exec.go" - ], - "cleveragents.infrastructure.process_runner": [ - "app/cli/cmd/exec.go", - "app/cli/plan_exec/exec_cmd.go", - "app/shared/exec.go" - ], - "cleveragents.domain.exec_results": [ - "app/cli/cmd/exec.go", - "app/cli/plan_exec/exec_cmd.go", - "app/shared/exec.go" - ], - "cleveragents.application.debug_service": [ - "app/cli/cmd/debug.go", - "app/cli/plan_exec/auto_debug.go", - "app/shared/debug.go" - ], - "cleveragents.domain.error_analysis": [ - "app/cli/cmd/debug.go", - "app/cli/plan_exec/auto_debug.go", - "app/shared/debug.go" - ], - "cleveragents.infrastructure.ai_debug": [ - "app/cli/cmd/debug.go", - "app/cli/plan_exec/auto_debug.go", - "app/shared/debug.go" - ], - "cleveragents.domain.branches": [ - "app/cli/cmd/branches.go", - "app/cli/lib/branch_helpers.go", - "app/server/db/branch_helpers.go" - ], - "cleveragents.application.branch_service": [ - "app/cli/cmd/branches.go", - "app/cli/lib/branch_helpers.go", - "app/server/db/branch_helpers.go" - ], - "cleveragents.cli.commands.branches": [ - "app/cli/cmd/branches.go", - "app/cli/lib/branch_helpers.go", - "app/server/db/branch_helpers.go" - ], - "cleveragents.application.merge_service": [ - "app/cli/cmd/merge.go", - "app/cli/lib/merge_helpers.go" - ], - "cleveragents.domain.conflict_resolution": [ - "app/cli/cmd/merge.go", - "app/cli/lib/merge_helpers.go" - ], - "cleveragents.infrastructure.auth": [ - "app/cli/cmd/sign_in.go", - "app/cli/lib/auth.go", - "app/server/handlers/auth_handlers.go", - "app/server/db/user_helpers.go" - ], - "cleveragents.domain.sessions": [ - "app/cli/cmd/sign_in.go", - "app/cli/lib/auth.go", - "app/server/handlers/auth_handlers.go", - "app/server/db/user_helpers.go" - ], - "cleveragents.cli.commands.auth": [ - "app/cli/cmd/sign_in.go", - "app/cli/lib/auth.go", - "app/server/handlers/auth_handlers.go", - "app/server/db/user_helpers.go" - ], - "cleveragents.domain.models": [ - "app/cli/cmd/models.go", - "app/cli/cmd/set_model.go", - "app/cli/lib/models_sync.go", - "app/shared/ai_models.go" - ], - "cleveragents.application.model_service": [ - "app/cli/cmd/models.go", - "app/cli/cmd/set_model.go", - "app/cli/lib/models_sync.go", - "app/shared/ai_models.go" - ], - "cleveragents.infrastructure.model_providers": [ - "app/cli/cmd/models.go", - "app/cli/cmd/set_model.go", - "app/cli/lib/models_sync.go", - "app/shared/ai_models.go" - ], - "cleveragents.cli.commands.models": [ - "app/cli/cmd/models.go", - "app/cli/cmd/set_model.go", - "app/cli/lib/models_sync.go", - "app/shared/ai_models.go" - ], - "cleveragents.infrastructure.config": [ - "app/cli/cmd/config.go", - "app/cli/lib/config.go", - "app/server/config/config.go" - ], - "cleveragents.domain.settings": [ - "app/cli/cmd/config.go", - "app/cli/lib/config.go", - "app/server/config/config.go" - ], - "cleveragents.cli.commands.config": [ - "app/cli/cmd/config.go", - "app/cli/lib/config.go", - "app/server/config/config.go" - ], - "cleveragents.domain.teams": [ - "app/cli/cmd/invite.go", - "app/server/handlers/invite_handlers.go", - "app/server/db/invite_helpers.go" - ], - "cleveragents.application.invite_service": [ - "app/cli/cmd/invite.go", - "app/server/handlers/invite_handlers.go", - "app/server/db/invite_helpers.go" - ], - "cleveragents.infrastructure.notifications": [ - "app/cli/cmd/invite.go", - "app/server/handlers/invite_handlers.go", - "app/server/db/invite_helpers.go" - ], - "cleveragents.infrastructure.streaming": [ - "app/cli/stream_tui/stream_tui.go", - "app/cli/lib/active_stream.go", - "app/server/handlers/stream_handlers.go" - ], - "cleveragents.application.stream_service": [ - "app/cli/stream_tui/stream_tui.go", - "app/cli/lib/active_stream.go", - "app/server/handlers/stream_handlers.go" - ], - "cleveragents.cli.ui.stream_renderer": [ - "app/cli/stream_tui/stream_tui.go", - "app/cli/lib/active_stream.go", - "app/server/handlers/stream_handlers.go" - ], - "cleveragents.infrastructure.jobs": [ - "app/server/db/job_helpers.go", - "app/server/workers/workers.go", - "app/cli/lib/background_tasks.go" - ], - "cleveragents.application.job_service": [ - "app/server/db/job_helpers.go", - "app/server/workers/workers.go", - "app/cli/lib/background_tasks.go" - ], - "cleveragents.domain.background_tasks": [ - "app/server/db/job_helpers.go", - "app/server/workers/workers.go", - "app/cli/lib/background_tasks.go" - ] - }, - "coverage_gaps": [], - "implementation_order": [ - "team_invite", - "auth_login", - "model_selection", - "background_jobs", - "auto_debug", - "config_management", - "context_load", - "plan_apply", - "branch_merge", - "branch_create", - "stream_updates", - "plan_build", - "plan_create", - "context_auto", - "exec_command" - ] - }, - "statistics": { - "total_workflows": 15, - "workflows_per_category": { - "plan_lifecycle": 3, - "context_management": 2, - "execution_flows": 2, - "branching": 2, - "authentication": 1, - "model_management": 1, - "configuration": 1, - "collaboration": 1, - "streaming": 1, - "background_jobs": 1 - }, - "total_go_components": 51, - "total_python_modules": 47, - "total_stages": 73, - "test_coverage": { - "with_behave": 15, - "with_robot": 15, - "with_go_tests": 1, - "without_tests": 0 - } - }, - "categories": { - "plan_lifecycle": "Plan creation, building, applying, and archiving", - "context_management": "Context loading, modification, and auto-detection", - "execution_flows": "Command execution, auto-debug, and rollback", - "branching": "Branch creation, switching, merging, and diff management", - "collaboration": "Team invites, sharing, and permissions", - "model_management": "Model selection, custom models, and provider configuration", - "authentication": "Login, logout, session management, and API keys", - "configuration": "Settings, environment variables, and config files", - "streaming": "Real-time updates, logs, and progress tracking", - "background_jobs": "Async tasks, retries, and job scheduling" - } -} \ No newline at end of file diff --git a/docs/reference/workflows/workflow_parity.md b/docs/reference/workflows/workflow_parity.md deleted file mode 100644 index 13819998a..000000000 --- a/docs/reference/workflows/workflow_parity.md +++ /dev/null @@ -1,378 +0,0 @@ -# Workflow Parity Matrix - -This document maps Plandex Go workflows to CleverAgents Python modules. - -## Summary Statistics - -- Total workflows: 15 -- Go components: 51 -- Python modules: 47 -- Total stages: 73 - -## Workflows by Category - -### Plan Lifecycle -Plan creation, building, applying, and archiving - -#### Plan Create -Create a new plan with initial context - -**Stages:** -1. initialization: Create plan structure and metadata -1. context_setup: Set up initial context and files -1. model_selection: Choose default model for the plan -1. persistence: Save plan to database/filesystem - -**Python Modules:** -- `cleveragents.domain.plans` -- `cleveragents.application.plan_service` -- `cleveragents.cli.commands.plan` - -**Test Coverage:** -- behave: features/plans.feature -- robot: robot/plan_lifecycle.robot -- go_tests: app/cli/cmd/plan_test.go - -**Notes:** Must maintain backward compatibility with existing plan formats - -#### Plan Build -Build plan by processing prompts through AI models - -**Stages:** -1. prompt_processing: Process user prompts and context -1. model_interaction: Send to AI model and get response -1. diff_generation: Generate diffs from AI response -1. validation: Validate generated changes -1. storage: Store diffs and conversation history - -**Python Modules:** -- `cleveragents.application.build_service` -- `cleveragents.domain.diffs` -- `cleveragents.infrastructure.ai_providers` -- `cleveragents.cli.commands.tell` - -**Test Coverage:** -- behave: features/plan_build.feature -- robot: robot/build_workflow.robot - -**Notes:** Streaming updates must match Go implementation timing - -#### Plan Apply -Apply plan changes to files with review and confirmation - -**Stages:** -1. diff_preview: Show pending changes to user -1. confirmation: Get user confirmation -1. file_updates: Apply diffs to files -1. git_operations: Optional git commit -1. cleanup: Clean up temporary files - -**Python Modules:** -- `cleveragents.application.apply_service` -- `cleveragents.domain.file_operations` -- `cleveragents.infrastructure.git_integration` -- `cleveragents.cli.commands.apply` - -**Test Coverage:** -- behave: features/apply.feature -- robot: robot/apply_workflow.robot - -**Notes:** Must handle merge conflicts and rollback on failure - -### Context Management -Context loading, modification, and auto-detection - -#### Context Load -Load files and directories into plan context - -**Stages:** -1. path_resolution: Resolve file paths and globs -1. content_reading: Read file contents -1. filtering: Apply ignore patterns -1. indexing: Index content for search -1. storage: Store in context database - -**Python Modules:** -- `cleveragents.domain.context` -- `cleveragents.application.context_service` -- `cleveragents.infrastructure.file_loader` -- `cleveragents.cli.commands.context` - -**Test Coverage:** -- behave: features/context.feature -- robot: robot/context_management.robot - -**Notes:** Auto-context detection must match Go heuristics - -#### Context Auto -Automatically detect and load relevant context - -**Stages:** -1. detection: Detect project type and structure -1. heuristics: Apply loading heuristics -1. filtering: Filter irrelevant files -1. loading: Load detected context - -**Python Modules:** -- `cleveragents.application.auto_context` -- `cleveragents.domain.heuristics` - -**Test Coverage:** -- behave: features/auto_context.feature -- robot: robot/auto_context.robot - -**Notes:** Heuristics extracted in implicit behaviors discovery - -### Execution Flows -Command execution, auto-debug, and rollback - -#### Exec Command -Execute commands in plan context with capture - -**Stages:** -1. command_parsing: Parse command and arguments -1. environment_setup: Set up execution environment -1. execution: Run command with output capture -1. result_processing: Process output and errors -1. context_update: Update context with results - -**Python Modules:** -- `cleveragents.application.exec_service` -- `cleveragents.infrastructure.process_runner` -- `cleveragents.domain.exec_results` - -**Test Coverage:** -- behave: features/exec.feature -- robot: robot/execution.robot - -**Notes:** Must support process groups and cgroup isolation - -#### Auto Debug -Automatically debug and retry failed operations - -**Stages:** -1. error_detection: Detect errors in output -1. error_analysis: Analyze error for fix strategy -1. fix_generation: Generate fix with AI model -1. fix_application: Apply fix and retry -1. validation: Validate fix succeeded - -**Python Modules:** -- `cleveragents.application.debug_service` -- `cleveragents.domain.error_analysis` -- `cleveragents.infrastructure.ai_debug` - -**Test Coverage:** -- behave: features/auto_debug.feature -- robot: robot/debug_workflow.robot - -**Notes:** Retry limits and backoff must match Go implementation - -### Branching -Branch creation, switching, merging, and diff management - -#### Branch Create -Create and switch plan branches - -**Stages:** -1. validation: Validate branch name -1. creation: Create branch structure -1. copying: Copy current state to branch -1. switching: Switch to new branch -1. persistence: Save branch metadata - -**Python Modules:** -- `cleveragents.domain.branches` -- `cleveragents.application.branch_service` -- `cleveragents.cli.commands.branches` - -**Test Coverage:** -- behave: features/branches.feature -- robot: robot/branching.robot - -**Notes:** Branch switching must preserve unsaved changes - -#### Branch Merge -Merge branches with conflict resolution - -**Stages:** -1. diff_comparison: Compare branch diffs -1. conflict_detection: Detect merge conflicts -1. conflict_resolution: Resolve conflicts -1. merge_application: Apply merged changes -1. cleanup: Clean up merged branch - -**Python Modules:** -- `cleveragents.application.merge_service` -- `cleveragents.domain.conflict_resolution` - -**Test Coverage:** -- behave: features/merge.feature -- robot: robot/merge_workflow.robot - -**Notes:** Must support manual and automatic conflict resolution - -### Collaboration -Team invites, sharing, and permissions - -#### Team Invite -Invite team members and manage permissions - -**Stages:** -1. invite_creation: Create invite -1. notification: Send invite notification -1. acceptance: Process invite acceptance -1. permission_grant: Grant permissions -1. sync: Sync team state - -**Python Modules:** -- `cleveragents.domain.teams` -- `cleveragents.application.invite_service` -- `cleveragents.infrastructure.notifications` - -**Test Coverage:** -- behave: features/collaboration.feature -- robot: robot/team_workflow.robot - -**Notes:** Replace cloud invites with SMTP or local alternatives - -### Model Management -Model selection, custom models, and provider configuration - -#### Model Selection -Select and configure AI models - -**Stages:** -1. model_listing: List available models -1. capability_check: Check model capabilities -1. selection: Select model -1. validation: Validate API keys -1. configuration: Save model configuration - -**Python Modules:** -- `cleveragents.domain.models` -- `cleveragents.application.model_service` -- `cleveragents.infrastructure.model_providers` -- `cleveragents.cli.commands.models` - -**Test Coverage:** -- behave: features/models.feature -- robot: robot/model_management.robot - -**Notes:** Model catalog refresh must be automated - -### Authentication -Login, logout, session management, and API keys - -#### Auth Login -User authentication and session establishment - -**Stages:** -1. credential_input: Get user credentials -1. authentication: Verify credentials -1. session_creation: Create session token -1. token_storage: Store token locally -1. verification: Verify session active - -**Python Modules:** -- `cleveragents.infrastructure.auth` -- `cleveragents.domain.sessions` -- `cleveragents.cli.commands.auth` - -**Test Coverage:** -- behave: features/authentication.feature -- robot: robot/auth_workflow.robot - -**Notes:** Must support both API key and email/password auth - -### Configuration -Settings, environment variables, and config files - -#### Config Management -Manage application configuration - -**Stages:** -1. config_loading: Load configuration files -1. env_merging: Merge environment variables -1. validation: Validate configuration -1. application: Apply configuration -1. persistence: Save configuration changes - -**Python Modules:** -- `cleveragents.infrastructure.config` -- `cleveragents.domain.settings` -- `cleveragents.cli.commands.config` - -**Test Coverage:** -- behave: features/configuration.feature -- robot: robot/config_management.robot - -**Notes:** Must support CLEVERAGENTS_ env vars exclusively - -### Streaming -Real-time updates, logs, and progress tracking - -#### Stream Updates -Stream real-time updates during operations - -**Stages:** -1. connection: Establish streaming connection -1. buffering: Buffer incoming chunks -1. rendering: Render updates to UI -1. error_handling: Handle connection errors -1. cleanup: Clean up on completion - -**Python Modules:** -- `cleveragents.infrastructure.streaming` -- `cleveragents.application.stream_service` -- `cleveragents.cli.ui.stream_renderer` - -**Test Coverage:** -- behave: features/streaming.feature -- robot: robot/streaming.robot - -**Notes:** Must handle reconnection and backpressure - -### Background Jobs -Async tasks, retries, and job scheduling - -#### Background Jobs -Manage background tasks and job scheduling - -**Stages:** -1. job_creation: Create job definition -1. scheduling: Schedule job execution -1. execution: Execute job task -1. retry: Retry on failure -1. completion: Mark job complete - -**Python Modules:** -- `cleveragents.infrastructure.jobs` -- `cleveragents.application.job_service` -- `cleveragents.domain.background_tasks` - -**Test Coverage:** -- behave: features/background_jobs.feature -- robot: robot/job_scheduling.robot - -**Notes:** Use asyncio or celery for job management - -## Recommended Implementation Order - -Based on dependency analysis: - -1. **team_invite** - Invite team members and manage permissions -2. **auth_login** - User authentication and session establishment -3. **model_selection** - Select and configure AI models -4. **background_jobs** - Manage background tasks and job scheduling -5. **auto_debug** - Automatically debug and retry failed operations -6. **config_management** - Manage application configuration -7. **context_load** - Load files and directories into plan context -8. **plan_apply** - Apply plan changes to files with review and confirmation -9. **branch_merge** - Merge branches with conflict resolution -10. **branch_create** - Create and switch plan branches -11. **stream_updates** - Stream real-time updates during operations -12. **plan_build** - Build plan by processing prompts through AI models -13. **plan_create** - Create a new plan with initial context -14. **context_auto** - Automatically detect and load relevant context -15. **exec_command** - Execute commands in plan context with capture diff --git a/docs/reference/workflows/workflow_parity.yaml b/docs/reference/workflows/workflow_parity.yaml deleted file mode 100644 index 77723bbbb..000000000 --- a/docs/reference/workflows/workflow_parity.yaml +++ /dev/null @@ -1,968 +0,0 @@ -workflows: - plan_create: - category: plan_lifecycle - description: Create a new plan with initial context - go_components: - - app/cli/cmd/plan.go - - app/cli/cmd/new.go - - app/cli/plan_exec/plan_exec.go - - app/server/handlers/plan_handlers.go - - app/server/db/plan_helpers.go - stages: - - name: initialization - description: Create plan structure and metadata - - name: context_setup - description: Set up initial context and files - - name: model_selection - description: Choose default model for the plan - - name: persistence - description: Save plan to database/filesystem - python_modules: - - cleveragents.domain.plans - - cleveragents.application.plan_service - - cleveragents.cli.commands.plan - test_coverage: - behave: - - features/plans.feature - robot: - - robot/plan_lifecycle.robot - go_tests: - - app/cli/cmd/plan_test.go - dependencies: - - authentication - - model_management - - persistence - notes: Must maintain backward compatibility with existing plan formats - plan_build: - category: plan_lifecycle - description: Build plan by processing prompts through AI models - go_components: - - app/cli/cmd/tell.go - - app/cli/cmd/continue.go - - app/cli/plan_exec/plan_build.go - - app/server/handlers/build_handlers.go - - app/shared/plan_build.go - stages: - - name: prompt_processing - description: Process user prompts and context - - name: model_interaction - description: Send to AI model and get response - - name: diff_generation - description: Generate diffs from AI response - - name: validation - description: Validate generated changes - - name: storage - description: Store diffs and conversation history - python_modules: - - cleveragents.application.build_service - - cleveragents.domain.diffs - - cleveragents.infrastructure.ai_providers - - cleveragents.cli.commands.tell - test_coverage: - behave: - - features/plan_build.feature - robot: - - robot/build_workflow.robot - dependencies: - - model_management - - diff_storage - - streaming - notes: Streaming updates must match Go implementation timing - plan_apply: - category: plan_lifecycle - description: Apply plan changes to files with review and confirmation - go_components: - - app/cli/cmd/apply.go - - app/cli/plan_exec/apply_plan.go - - app/server/handlers/apply_handlers.go - - app/shared/apply.go - stages: - - name: diff_preview - description: Show pending changes to user - - name: confirmation - description: Get user confirmation - - name: file_updates - description: Apply diffs to files - - name: git_operations - description: Optional git commit - - name: cleanup - description: Clean up temporary files - python_modules: - - cleveragents.application.apply_service - - cleveragents.domain.file_operations - - cleveragents.infrastructure.git_integration - - cleveragents.cli.commands.apply - test_coverage: - behave: - - features/apply.feature - robot: - - robot/apply_workflow.robot - dependencies: - - diff_management - - file_operations - - git_integration - notes: Must handle merge conflicts and rollback on failure - context_load: - category: context_management - description: Load files and directories into plan context - go_components: - - app/cli/cmd/context.go - - app/cli/cmd/load.go - - app/cli/lib/context_loader.go - - app/server/db/context_helpers.go - stages: - - name: path_resolution - description: Resolve file paths and globs - - name: content_reading - description: Read file contents - - name: filtering - description: Apply ignore patterns - - name: indexing - description: Index content for search - - name: storage - description: Store in context database - python_modules: - - cleveragents.domain.context - - cleveragents.application.context_service - - cleveragents.infrastructure.file_loader - - cleveragents.cli.commands.context - test_coverage: - behave: - - features/context.feature - robot: - - robot/context_management.robot - dependencies: - - file_operations - - path_resolution - - indexing - notes: Auto-context detection must match Go heuristics - context_auto: - category: context_management - description: Automatically detect and load relevant context - go_components: - - app/cli/lib/context_auto.go - - app/cli/lib/context_heuristics.go - stages: - - name: detection - description: Detect project type and structure - - name: heuristics - description: Apply loading heuristics - - name: filtering - description: Filter irrelevant files - - name: loading - description: Load detected context - python_modules: - - cleveragents.application.auto_context - - cleveragents.domain.heuristics - test_coverage: - behave: - - features/auto_context.feature - robot: - - robot/auto_context.robot - dependencies: - - context_load - - project_detection - notes: Heuristics extracted in implicit behaviors discovery - exec_command: - category: execution_flows - description: Execute commands in plan context with capture - go_components: - - app/cli/cmd/exec.go - - app/cli/plan_exec/exec_cmd.go - - app/shared/exec.go - stages: - - name: command_parsing - description: Parse command and arguments - - name: environment_setup - description: Set up execution environment - - name: execution - description: Run command with output capture - - name: result_processing - description: Process output and errors - - name: context_update - description: Update context with results - python_modules: - - cleveragents.application.exec_service - - cleveragents.infrastructure.process_runner - - cleveragents.domain.exec_results - test_coverage: - behave: - - features/exec.feature - robot: - - robot/execution.robot - dependencies: - - process_isolation - - output_capture - - context_management - notes: Must support process groups and cgroup isolation - auto_debug: - category: execution_flows - description: Automatically debug and retry failed operations - go_components: - - app/cli/cmd/debug.go - - app/cli/plan_exec/auto_debug.go - - app/shared/debug.go - stages: - - name: error_detection - description: Detect errors in output - - name: error_analysis - description: Analyze error for fix strategy - - name: fix_generation - description: Generate fix with AI model - - name: fix_application - description: Apply fix and retry - - name: validation - description: Validate fix succeeded - python_modules: - - cleveragents.application.debug_service - - cleveragents.domain.error_analysis - - cleveragents.infrastructure.ai_debug - test_coverage: - behave: - - features/auto_debug.feature - robot: - - robot/debug_workflow.robot - dependencies: - - error_detection - - model_interaction - - retry_logic - notes: Retry limits and backoff must match Go implementation - branch_create: - category: branching - description: Create and switch plan branches - go_components: - - app/cli/cmd/branches.go - - app/cli/lib/branch_helpers.go - - app/server/db/branch_helpers.go - stages: - - name: validation - description: Validate branch name - - name: creation - description: Create branch structure - - name: copying - description: Copy current state to branch - - name: switching - description: Switch to new branch - - name: persistence - description: Save branch metadata - python_modules: - - cleveragents.domain.branches - - cleveragents.application.branch_service - - cleveragents.cli.commands.branches - test_coverage: - behave: - - features/branches.feature - robot: - - robot/branching.robot - dependencies: - - plan_management - - diff_storage - - state_management - notes: Branch switching must preserve unsaved changes - branch_merge: - category: branching - description: Merge branches with conflict resolution - go_components: - - app/cli/cmd/merge.go - - app/cli/lib/merge_helpers.go - stages: - - name: diff_comparison - description: Compare branch diffs - - name: conflict_detection - description: Detect merge conflicts - - name: conflict_resolution - description: Resolve conflicts - - name: merge_application - description: Apply merged changes - - name: cleanup - description: Clean up merged branch - python_modules: - - cleveragents.application.merge_service - - cleveragents.domain.conflict_resolution - test_coverage: - behave: - - features/merge.feature - robot: - - robot/merge_workflow.robot - dependencies: - - diff_management - - conflict_detection - - state_management - notes: Must support manual and automatic conflict resolution - auth_login: - category: authentication - description: User authentication and session establishment - go_components: - - app/cli/cmd/sign_in.go - - app/cli/lib/auth.go - - app/server/handlers/auth_handlers.go - - app/server/db/user_helpers.go - stages: - - name: credential_input - description: Get user credentials - - name: authentication - description: Verify credentials - - name: session_creation - description: Create session token - - name: token_storage - description: Store token locally - - name: verification - description: Verify session active - python_modules: - - cleveragents.infrastructure.auth - - cleveragents.domain.sessions - - cleveragents.cli.commands.auth - test_coverage: - behave: - - features/authentication.feature - robot: - - robot/auth_workflow.robot - dependencies: - - user_management - - token_management - - encryption - notes: Must support both API key and email/password auth - model_selection: - category: model_management - description: Select and configure AI models - go_components: - - app/cli/cmd/models.go - - app/cli/cmd/set_model.go - - app/cli/lib/models_sync.go - - app/shared/ai_models.go - stages: - - name: model_listing - description: List available models - - name: capability_check - description: Check model capabilities - - name: selection - description: Select model - - name: validation - description: Validate API keys - - name: configuration - description: Save model configuration - python_modules: - - cleveragents.domain.models - - cleveragents.application.model_service - - cleveragents.infrastructure.model_providers - - cleveragents.cli.commands.models - test_coverage: - behave: - - features/models.feature - robot: - - robot/model_management.robot - dependencies: - - provider_integration - - api_key_management - - model_catalog - notes: Model catalog refresh must be automated - config_management: - category: configuration - description: Manage application configuration - go_components: - - app/cli/cmd/config.go - - app/cli/lib/config.go - - app/server/config/config.go - stages: - - name: config_loading - description: Load configuration files - - name: env_merging - description: Merge environment variables - - name: validation - description: Validate configuration - - name: application - description: Apply configuration - - name: persistence - description: Save configuration changes - python_modules: - - cleveragents.infrastructure.config - - cleveragents.domain.settings - - cleveragents.cli.commands.config - test_coverage: - behave: - - features/configuration.feature - robot: - - robot/config_management.robot - dependencies: - - file_operations - - env_variables - - validation - notes: Must support CLEVERAGENTS_ env vars exclusively - team_invite: - category: collaboration - description: Invite team members and manage permissions - go_components: - - app/cli/cmd/invite.go - - app/server/handlers/invite_handlers.go - - app/server/db/invite_helpers.go - stages: - - name: invite_creation - description: Create invite - - name: notification - description: Send invite notification - - name: acceptance - description: Process invite acceptance - - name: permission_grant - description: Grant permissions - - name: sync - description: Sync team state - python_modules: - - cleveragents.domain.teams - - cleveragents.application.invite_service - - cleveragents.infrastructure.notifications - test_coverage: - behave: - - features/collaboration.feature - robot: - - robot/team_workflow.robot - dependencies: - - user_management - - permissions - - notifications - notes: Replace cloud invites with SMTP or local alternatives - stream_updates: - category: streaming - description: Stream real-time updates during operations - go_components: - - app/cli/stream_tui/stream_tui.go - - app/cli/lib/active_stream.go - - app/server/handlers/stream_handlers.go - stages: - - name: connection - description: Establish streaming connection - - name: buffering - description: Buffer incoming chunks - - name: rendering - description: Render updates to UI - - name: error_handling - description: Handle connection errors - - name: cleanup - description: Clean up on completion - python_modules: - - cleveragents.infrastructure.streaming - - cleveragents.application.stream_service - - cleveragents.cli.ui.stream_renderer - test_coverage: - behave: - - features/streaming.feature - robot: - - robot/streaming.robot - dependencies: - - websockets - - ui_rendering - - backpressure - notes: Must handle reconnection and backpressure - background_jobs: - category: background_jobs - description: Manage background tasks and job scheduling - go_components: - - app/server/db/job_helpers.go - - app/server/workers/workers.go - - app/cli/lib/background_tasks.go - stages: - - name: job_creation - description: Create job definition - - name: scheduling - description: Schedule job execution - - name: execution - description: Execute job task - - name: retry - description: Retry on failure - - name: completion - description: Mark job complete - python_modules: - - cleveragents.infrastructure.jobs - - cleveragents.application.job_service - - cleveragents.domain.background_tasks - test_coverage: - behave: - - features/background_jobs.feature - robot: - - robot/job_scheduling.robot - dependencies: - - task_queue - - retry_logic - - scheduling - notes: Use asyncio or celery for job management -matrix: - go_to_python: - app/cli/cmd/plan.go: - - cleveragents.domain.plans - - cleveragents.application.plan_service - - cleveragents.cli.commands.plan - app/cli/cmd/new.go: - - cleveragents.domain.plans - - cleveragents.application.plan_service - - cleveragents.cli.commands.plan - app/cli/plan_exec/plan_exec.go: - - cleveragents.domain.plans - - cleveragents.application.plan_service - - cleveragents.cli.commands.plan - app/server/handlers/plan_handlers.go: - - cleveragents.domain.plans - - cleveragents.application.plan_service - - cleveragents.cli.commands.plan - app/server/db/plan_helpers.go: - - cleveragents.domain.plans - - cleveragents.application.plan_service - - cleveragents.cli.commands.plan - app/cli/cmd/tell.go: - - cleveragents.application.build_service - - cleveragents.domain.diffs - - cleveragents.infrastructure.ai_providers - - cleveragents.cli.commands.tell - app/cli/cmd/continue.go: - - cleveragents.application.build_service - - cleveragents.domain.diffs - - cleveragents.infrastructure.ai_providers - - cleveragents.cli.commands.tell - app/cli/plan_exec/plan_build.go: - - cleveragents.application.build_service - - cleveragents.domain.diffs - - cleveragents.infrastructure.ai_providers - - cleveragents.cli.commands.tell - app/server/handlers/build_handlers.go: - - cleveragents.application.build_service - - cleveragents.domain.diffs - - cleveragents.infrastructure.ai_providers - - cleveragents.cli.commands.tell - app/shared/plan_build.go: - - cleveragents.application.build_service - - cleveragents.domain.diffs - - cleveragents.infrastructure.ai_providers - - cleveragents.cli.commands.tell - app/cli/cmd/apply.go: - - cleveragents.application.apply_service - - cleveragents.domain.file_operations - - cleveragents.infrastructure.git_integration - - cleveragents.cli.commands.apply - app/cli/plan_exec/apply_plan.go: - - cleveragents.application.apply_service - - cleveragents.domain.file_operations - - cleveragents.infrastructure.git_integration - - cleveragents.cli.commands.apply - app/server/handlers/apply_handlers.go: - - cleveragents.application.apply_service - - cleveragents.domain.file_operations - - cleveragents.infrastructure.git_integration - - cleveragents.cli.commands.apply - app/shared/apply.go: - - cleveragents.application.apply_service - - cleveragents.domain.file_operations - - cleveragents.infrastructure.git_integration - - cleveragents.cli.commands.apply - app/cli/cmd/context.go: - - cleveragents.domain.context - - cleveragents.application.context_service - - cleveragents.infrastructure.file_loader - - cleveragents.cli.commands.context - app/cli/cmd/load.go: - - cleveragents.domain.context - - cleveragents.application.context_service - - cleveragents.infrastructure.file_loader - - cleveragents.cli.commands.context - app/cli/lib/context_loader.go: - - cleveragents.domain.context - - cleveragents.application.context_service - - cleveragents.infrastructure.file_loader - - cleveragents.cli.commands.context - app/server/db/context_helpers.go: - - cleveragents.domain.context - - cleveragents.application.context_service - - cleveragents.infrastructure.file_loader - - cleveragents.cli.commands.context - app/cli/lib/context_auto.go: - - cleveragents.application.auto_context - - cleveragents.domain.heuristics - app/cli/lib/context_heuristics.go: - - cleveragents.application.auto_context - - cleveragents.domain.heuristics - app/cli/cmd/exec.go: - - cleveragents.application.exec_service - - cleveragents.infrastructure.process_runner - - cleveragents.domain.exec_results - app/cli/plan_exec/exec_cmd.go: - - cleveragents.application.exec_service - - cleveragents.infrastructure.process_runner - - cleveragents.domain.exec_results - app/shared/exec.go: - - cleveragents.application.exec_service - - cleveragents.infrastructure.process_runner - - cleveragents.domain.exec_results - app/cli/cmd/debug.go: - - cleveragents.application.debug_service - - cleveragents.domain.error_analysis - - cleveragents.infrastructure.ai_debug - app/cli/plan_exec/auto_debug.go: - - cleveragents.application.debug_service - - cleveragents.domain.error_analysis - - cleveragents.infrastructure.ai_debug - app/shared/debug.go: - - cleveragents.application.debug_service - - cleveragents.domain.error_analysis - - cleveragents.infrastructure.ai_debug - app/cli/cmd/branches.go: - - cleveragents.domain.branches - - cleveragents.application.branch_service - - cleveragents.cli.commands.branches - app/cli/lib/branch_helpers.go: - - cleveragents.domain.branches - - cleveragents.application.branch_service - - cleveragents.cli.commands.branches - app/server/db/branch_helpers.go: - - cleveragents.domain.branches - - cleveragents.application.branch_service - - cleveragents.cli.commands.branches - app/cli/cmd/merge.go: - - cleveragents.application.merge_service - - cleveragents.domain.conflict_resolution - app/cli/lib/merge_helpers.go: - - cleveragents.application.merge_service - - cleveragents.domain.conflict_resolution - app/cli/cmd/sign_in.go: - - cleveragents.infrastructure.auth - - cleveragents.domain.sessions - - cleveragents.cli.commands.auth - app/cli/lib/auth.go: - - cleveragents.infrastructure.auth - - cleveragents.domain.sessions - - cleveragents.cli.commands.auth - app/server/handlers/auth_handlers.go: - - cleveragents.infrastructure.auth - - cleveragents.domain.sessions - - cleveragents.cli.commands.auth - app/server/db/user_helpers.go: - - cleveragents.infrastructure.auth - - cleveragents.domain.sessions - - cleveragents.cli.commands.auth - app/cli/cmd/models.go: - - cleveragents.domain.models - - cleveragents.application.model_service - - cleveragents.infrastructure.model_providers - - cleveragents.cli.commands.models - app/cli/cmd/set_model.go: - - cleveragents.domain.models - - cleveragents.application.model_service - - cleveragents.infrastructure.model_providers - - cleveragents.cli.commands.models - app/cli/lib/models_sync.go: - - cleveragents.domain.models - - cleveragents.application.model_service - - cleveragents.infrastructure.model_providers - - cleveragents.cli.commands.models - app/shared/ai_models.go: - - cleveragents.domain.models - - cleveragents.application.model_service - - cleveragents.infrastructure.model_providers - - cleveragents.cli.commands.models - app/cli/cmd/config.go: - - cleveragents.infrastructure.config - - cleveragents.domain.settings - - cleveragents.cli.commands.config - app/cli/lib/config.go: - - cleveragents.infrastructure.config - - cleveragents.domain.settings - - cleveragents.cli.commands.config - app/server/config/config.go: - - cleveragents.infrastructure.config - - cleveragents.domain.settings - - cleveragents.cli.commands.config - app/cli/cmd/invite.go: - - cleveragents.domain.teams - - cleveragents.application.invite_service - - cleveragents.infrastructure.notifications - app/server/handlers/invite_handlers.go: - - cleveragents.domain.teams - - cleveragents.application.invite_service - - cleveragents.infrastructure.notifications - app/server/db/invite_helpers.go: - - cleveragents.domain.teams - - cleveragents.application.invite_service - - cleveragents.infrastructure.notifications - app/cli/stream_tui/stream_tui.go: - - cleveragents.infrastructure.streaming - - cleveragents.application.stream_service - - cleveragents.cli.ui.stream_renderer - app/cli/lib/active_stream.go: - - cleveragents.infrastructure.streaming - - cleveragents.application.stream_service - - cleveragents.cli.ui.stream_renderer - app/server/handlers/stream_handlers.go: - - cleveragents.infrastructure.streaming - - cleveragents.application.stream_service - - cleveragents.cli.ui.stream_renderer - app/server/db/job_helpers.go: - - cleveragents.infrastructure.jobs - - cleveragents.application.job_service - - cleveragents.domain.background_tasks - app/server/workers/workers.go: - - cleveragents.infrastructure.jobs - - cleveragents.application.job_service - - cleveragents.domain.background_tasks - app/cli/lib/background_tasks.go: - - cleveragents.infrastructure.jobs - - cleveragents.application.job_service - - cleveragents.domain.background_tasks - python_to_go: - cleveragents.domain.plans: - - app/cli/cmd/plan.go - - app/cli/cmd/new.go - - app/cli/plan_exec/plan_exec.go - - app/server/handlers/plan_handlers.go - - app/server/db/plan_helpers.go - cleveragents.application.plan_service: - - app/cli/cmd/plan.go - - app/cli/cmd/new.go - - app/cli/plan_exec/plan_exec.go - - app/server/handlers/plan_handlers.go - - app/server/db/plan_helpers.go - cleveragents.cli.commands.plan: - - app/cli/cmd/plan.go - - app/cli/cmd/new.go - - app/cli/plan_exec/plan_exec.go - - app/server/handlers/plan_handlers.go - - app/server/db/plan_helpers.go - cleveragents.application.build_service: - - app/cli/cmd/tell.go - - app/cli/cmd/continue.go - - app/cli/plan_exec/plan_build.go - - app/server/handlers/build_handlers.go - - app/shared/plan_build.go - cleveragents.domain.diffs: - - app/cli/cmd/tell.go - - app/cli/cmd/continue.go - - app/cli/plan_exec/plan_build.go - - app/server/handlers/build_handlers.go - - app/shared/plan_build.go - cleveragents.infrastructure.ai_providers: - - app/cli/cmd/tell.go - - app/cli/cmd/continue.go - - app/cli/plan_exec/plan_build.go - - app/server/handlers/build_handlers.go - - app/shared/plan_build.go - cleveragents.cli.commands.tell: - - app/cli/cmd/tell.go - - app/cli/cmd/continue.go - - app/cli/plan_exec/plan_build.go - - app/server/handlers/build_handlers.go - - app/shared/plan_build.go - cleveragents.application.apply_service: - - app/cli/cmd/apply.go - - app/cli/plan_exec/apply_plan.go - - app/server/handlers/apply_handlers.go - - app/shared/apply.go - cleveragents.domain.file_operations: - - app/cli/cmd/apply.go - - app/cli/plan_exec/apply_plan.go - - app/server/handlers/apply_handlers.go - - app/shared/apply.go - cleveragents.infrastructure.git_integration: - - app/cli/cmd/apply.go - - app/cli/plan_exec/apply_plan.go - - app/server/handlers/apply_handlers.go - - app/shared/apply.go - cleveragents.cli.commands.apply: - - app/cli/cmd/apply.go - - app/cli/plan_exec/apply_plan.go - - app/server/handlers/apply_handlers.go - - app/shared/apply.go - cleveragents.domain.context: - - app/cli/cmd/context.go - - app/cli/cmd/load.go - - app/cli/lib/context_loader.go - - app/server/db/context_helpers.go - cleveragents.application.context_service: - - app/cli/cmd/context.go - - app/cli/cmd/load.go - - app/cli/lib/context_loader.go - - app/server/db/context_helpers.go - cleveragents.infrastructure.file_loader: - - app/cli/cmd/context.go - - app/cli/cmd/load.go - - app/cli/lib/context_loader.go - - app/server/db/context_helpers.go - cleveragents.cli.commands.context: - - app/cli/cmd/context.go - - app/cli/cmd/load.go - - app/cli/lib/context_loader.go - - app/server/db/context_helpers.go - cleveragents.application.auto_context: - - app/cli/lib/context_auto.go - - app/cli/lib/context_heuristics.go - cleveragents.domain.heuristics: - - app/cli/lib/context_auto.go - - app/cli/lib/context_heuristics.go - cleveragents.application.exec_service: - - app/cli/cmd/exec.go - - app/cli/plan_exec/exec_cmd.go - - app/shared/exec.go - cleveragents.infrastructure.process_runner: - - app/cli/cmd/exec.go - - app/cli/plan_exec/exec_cmd.go - - app/shared/exec.go - cleveragents.domain.exec_results: - - app/cli/cmd/exec.go - - app/cli/plan_exec/exec_cmd.go - - app/shared/exec.go - cleveragents.application.debug_service: - - app/cli/cmd/debug.go - - app/cli/plan_exec/auto_debug.go - - app/shared/debug.go - cleveragents.domain.error_analysis: - - app/cli/cmd/debug.go - - app/cli/plan_exec/auto_debug.go - - app/shared/debug.go - cleveragents.infrastructure.ai_debug: - - app/cli/cmd/debug.go - - app/cli/plan_exec/auto_debug.go - - app/shared/debug.go - cleveragents.domain.branches: - - app/cli/cmd/branches.go - - app/cli/lib/branch_helpers.go - - app/server/db/branch_helpers.go - cleveragents.application.branch_service: - - app/cli/cmd/branches.go - - app/cli/lib/branch_helpers.go - - app/server/db/branch_helpers.go - cleveragents.cli.commands.branches: - - app/cli/cmd/branches.go - - app/cli/lib/branch_helpers.go - - app/server/db/branch_helpers.go - cleveragents.application.merge_service: - - app/cli/cmd/merge.go - - app/cli/lib/merge_helpers.go - cleveragents.domain.conflict_resolution: - - app/cli/cmd/merge.go - - app/cli/lib/merge_helpers.go - cleveragents.infrastructure.auth: - - app/cli/cmd/sign_in.go - - app/cli/lib/auth.go - - app/server/handlers/auth_handlers.go - - app/server/db/user_helpers.go - cleveragents.domain.sessions: - - app/cli/cmd/sign_in.go - - app/cli/lib/auth.go - - app/server/handlers/auth_handlers.go - - app/server/db/user_helpers.go - cleveragents.cli.commands.auth: - - app/cli/cmd/sign_in.go - - app/cli/lib/auth.go - - app/server/handlers/auth_handlers.go - - app/server/db/user_helpers.go - cleveragents.domain.models: - - app/cli/cmd/models.go - - app/cli/cmd/set_model.go - - app/cli/lib/models_sync.go - - app/shared/ai_models.go - cleveragents.application.model_service: - - app/cli/cmd/models.go - - app/cli/cmd/set_model.go - - app/cli/lib/models_sync.go - - app/shared/ai_models.go - cleveragents.infrastructure.model_providers: - - app/cli/cmd/models.go - - app/cli/cmd/set_model.go - - app/cli/lib/models_sync.go - - app/shared/ai_models.go - cleveragents.cli.commands.models: - - app/cli/cmd/models.go - - app/cli/cmd/set_model.go - - app/cli/lib/models_sync.go - - app/shared/ai_models.go - cleveragents.infrastructure.config: - - app/cli/cmd/config.go - - app/cli/lib/config.go - - app/server/config/config.go - cleveragents.domain.settings: - - app/cli/cmd/config.go - - app/cli/lib/config.go - - app/server/config/config.go - cleveragents.cli.commands.config: - - app/cli/cmd/config.go - - app/cli/lib/config.go - - app/server/config/config.go - cleveragents.domain.teams: - - app/cli/cmd/invite.go - - app/server/handlers/invite_handlers.go - - app/server/db/invite_helpers.go - cleveragents.application.invite_service: - - app/cli/cmd/invite.go - - app/server/handlers/invite_handlers.go - - app/server/db/invite_helpers.go - cleveragents.infrastructure.notifications: - - app/cli/cmd/invite.go - - app/server/handlers/invite_handlers.go - - app/server/db/invite_helpers.go - cleveragents.infrastructure.streaming: - - app/cli/stream_tui/stream_tui.go - - app/cli/lib/active_stream.go - - app/server/handlers/stream_handlers.go - cleveragents.application.stream_service: - - app/cli/stream_tui/stream_tui.go - - app/cli/lib/active_stream.go - - app/server/handlers/stream_handlers.go - cleveragents.cli.ui.stream_renderer: - - app/cli/stream_tui/stream_tui.go - - app/cli/lib/active_stream.go - - app/server/handlers/stream_handlers.go - cleveragents.infrastructure.jobs: - - app/server/db/job_helpers.go - - app/server/workers/workers.go - - app/cli/lib/background_tasks.go - cleveragents.application.job_service: - - app/server/db/job_helpers.go - - app/server/workers/workers.go - - app/cli/lib/background_tasks.go - cleveragents.domain.background_tasks: - - app/server/db/job_helpers.go - - app/server/workers/workers.go - - app/cli/lib/background_tasks.go - coverage_gaps: [] - implementation_order: - - team_invite - - auth_login - - model_selection - - background_jobs - - auto_debug - - config_management - - context_load - - plan_apply - - branch_merge - - branch_create - - stream_updates - - plan_build - - plan_create - - context_auto - - exec_command -statistics: - total_workflows: 15 - workflows_per_category: - plan_lifecycle: 3 - context_management: 2 - execution_flows: 2 - branching: 2 - authentication: 1 - model_management: 1 - configuration: 1 - collaboration: 1 - streaming: 1 - background_jobs: 1 - total_go_components: 51 - total_python_modules: 47 - total_stages: 73 - test_coverage: - with_behave: 15 - with_robot: 15 - with_go_tests: 1 - without_tests: 0 -categories: - plan_lifecycle: Plan creation, building, applying, and archiving - context_management: Context loading, modification, and auto-detection - execution_flows: Command execution, auto-debug, and rollback - branching: Branch creation, switching, merging, and diff management - collaboration: Team invites, sharing, and permissions - model_management: Model selection, custom models, and provider configuration - authentication: Login, logout, session management, and API keys - configuration: Settings, environment variables, and config files - streaming: Real-time updates, logs, and progress tracking - background_jobs: Async tasks, retries, and job scheduling diff --git a/features/cloud_features.feature b/features/cloud_features.feature deleted file mode 100644 index b3e7d9c07..000000000 --- a/features/cloud_features.feature +++ /dev/null @@ -1,56 +0,0 @@ -Feature: Cloud Features Identification - As a developer creating a self-hosted CleverAgents - I want to identify cloud-only features in Plandex - So that I can remove or replace them appropriately - - Background: - Given the Plandex Go codebase is available - And the cloud features extractor is initialized - - Scenario: Extract all cloud features - When I run the cloud features extraction - Then I should identify features in all categories - And each feature should have an action specified - And each feature should have a priority assigned - And the statistics should include feature counts - - Scenario: Identify billing features - When I scan for billing features - Then I should find billing_ui feature - And I should find usage_limits feature - And each billing feature should have replacement strategy - - Scenario: Identify telemetry features - When I scan for telemetry features - Then I should find usage_telemetry feature - And I should find error_reporting feature - And telemetry should default to opt-in local alternatives - - Scenario: Identify authentication features - When I scan for managed auth features - Then I should find managed_auth feature - And I should find api_keys_cloud feature - And auth features should have local replacements - - Scenario: Generate replacement strategies - When I extract cloud features and generate strategies - Then features should be categorized by action - And remove features should be listed - And replace features should have alternatives - And strategies should be sorted by priority - - Scenario: Save cloud features analysis - Given I have identified cloud features - When I save the cloud features results - Then a JSON file should be created with feature data - And a YAML file should be created with feature data - And a cloud features Markdown documentation should be generated - And the documentation should include replacement strategies - - Scenario: Calculate cloud feature statistics - When I extract all cloud features - Then the statistics should include total features - And the statistics should count features by category - And the statistics should count features by action - And the statistics should count features by priority - And the statistics should count affected Go files \ No newline at end of file diff --git a/features/data_contracts.feature b/features/data_contracts.feature deleted file mode 100644 index 0785a8c53..000000000 --- a/features/data_contracts.feature +++ /dev/null @@ -1,44 +0,0 @@ -@discovery -Feature: Data Contract Extraction - As a CleverAgents developer - I want to extract data contracts from Plandex shared Go code - So that I can generate Python dataclass equivalents - - Background: - Given the Plandex repository exists at "../plandex" - And the shared directory contains Go contract files - - Scenario: Extract structs from Go files - When I run the data contract extractor - Then contracts should be extracted from multiple modules - And each contract should contain structs with fields - And struct fields should have type information - And JSON tags should be preserved - - Scenario: Extract enums and type aliases - When I run the data contract extractor - Then enums should be identified from const blocks - And type aliases should be extracted - And each enum should have a list of values - - Scenario: Generate Python dataclass stubs - When I run the data contract extractor - And I generate Python stubs - Then Python files should be created for each module - And dataclasses should match Go struct definitions - And field types should be converted to Python types - And optional fields should use Optional type hints - - Scenario: Generate example fixtures - When I run the data contract extractor - And I generate example fixtures - Then JSON fixtures should be created for each struct - And fixtures should contain valid example data - And field names should use JSON tags when present - - Scenario: Save contracts as JSON and YAML - When I run the data contract extractor - And I save the contracts - Then a JSON file should be created with all contracts - And a YAML file should be created with all contracts - And both files should contain the same data structure \ No newline at end of file diff --git a/features/discovery.feature b/features/discovery.feature deleted file mode 100644 index 782d67bea..000000000 --- a/features/discovery.feature +++ /dev/null @@ -1,44 +0,0 @@ -@discovery -Feature: CLI Inventory Extraction - As a developer migrating Plandex to CleverAgents - I want to extract CLI command metadata from the Go codebase - So that I can ensure feature parity in the Python implementation - - Background: - Given the Plandex Go codebase is available - And the CLI inventory extractor is initialized - - Scenario: Extract CLI commands from Go source - When I run the CLI inventory extraction - Then the extraction should succeed - And at least 60 commands should be extracted - And the inventory should contain a root command - And the inventory should include command metadata - And the inventory files should be saved - - Scenario: Validate extracted command structure - Given the CLI inventory has been extracted - When I check the command structure - Then each command should have a name - And each command should have a file_path - And auth requirements should be detected - And project requirements should be detected - - Scenario: Export inventory in multiple formats - When I save the CLI inventory - Then a YAML file should be created at "docs/reference/cli_inventory.yaml" - And a JSON file should be created at "docs/reference/cli_inventory.json" - And both files should contain the same data - - Scenario: Detect command aliases - Given the CLI inventory has been extracted - When I check for command aliases - Then commands with aliases should be identified - And the aliases should be properly formatted - - Scenario: Extract command flags - Given the CLI inventory has been extracted - When I check for command flags - Then commands with flags should be identified - And flag metadata should include name and type - And flag descriptions should be captured \ No newline at end of file diff --git a/features/discovery_module.feature b/features/discovery_module.feature deleted file mode 100644 index 152ca22d8..000000000 --- a/features/discovery_module.feature +++ /dev/null @@ -1,41 +0,0 @@ -@discovery -Feature: Discovery Module Functions - As a developer - I want to test the discovery module functionality - So that I have confidence in the extraction tools - - Scenario: Import discovery module - When I import the discovery module - Then it should have CLIInventoryExtractor available - - Scenario: Run discovery main script - When I run the discovery CLI inventory main - Then it should extract and save the inventory - - Scenario: Parse Go variable names to command names - Given a CLI inventory extractor instance - When I convert "applyCmd" to command name - Then the converted name should be "apply" - When I convert "deleteIplanCmd" to command name - Then the converted name should be "delete-iplan" - When I convert "setModelCmd" to command name - Then the converted name should be "set-model" - - Scenario: Build command hierarchy - Given a CLI inventory extractor instance - When I build the command hierarchy - Then it should return a hierarchical structure - - Scenario: Gather statistics - Given a CLI inventory extractor instance - When I gather statistics about extracted commands - Then statistics should include total_commands - And statistics should include commands_with_aliases - And statistics should include commands_with_flags - - Scenario: Extract additional metadata - Given a CLI inventory extractor instance - When I extract additional metadata - Then metadata should include repl_commands - And metadata should include shortcuts - And metadata should include environment_variables \ No newline at end of file diff --git a/features/discovery_run_all.feature b/features/discovery_run_all.feature deleted file mode 100644 index d1aefb2fa..000000000 --- a/features/discovery_run_all.feature +++ /dev/null @@ -1,14 +0,0 @@ -@discovery -Feature: Run All Discovery Tools - As a developer - I want to run all discovery tools in one command - So that I can extract all metadata efficiently - - Scenario: Import run_all module - When I import the run_all module from discovery - Then it should have a main function - - Scenario: Execute run_all main function - When I execute the run_all main function - Then it should run successfully - And it should extract CLI inventory \ No newline at end of file diff --git a/features/env_variables.feature b/features/env_variables.feature deleted file mode 100644 index 7b379b400..000000000 --- a/features/env_variables.feature +++ /dev/null @@ -1,41 +0,0 @@ -@discovery -Feature: Environment Variable Extraction - As a developer migrating from Plandex to CleverAgents - I need to extract and map environment variables from Go code and docs - So that I can provide compatibility and migration guidance - - Scenario: Extract environment variables from documentation - Given a Plandex directory with environment variable documentation - When I extract environment variables from documentation - Then the extractor should find documented variables - And each variable should have a description - And each variable should have a proposed CleverAgents name - - Scenario: Extract environment variables from Go source code - Given a Plandex directory with Go source files - When I extract environment variables from Go code - Then the extractor should find code-referenced variables - And usage locations should be tracked - And variables should be categorized by source location - - Scenario: Generate environment variable mapping - Given an extracted set of environment variables - When I generate the mapping table - Then PLANDEX variables should map to CLEVERAGENTS equivalents - And provider-specific variables should remain unchanged - And generic variables should get CLEVERAGENTS prefix - - Scenario: Identify migration conflicts - Given an extracted set of environment variables - When I identify conflicts - Then PLANDEX_ prefixed variables should be flagged for migration - And development-only variables should be identified - And migration guidance should be provided - - Scenario: Save environment variable results - Given an extracted set of environment variables - When I save the results - Then a JSON file should be created - And a YAML file should be created - And a mapping text file should be created - And a migration guide should be generated \ No newline at end of file diff --git a/features/environment.py b/features/environment.py index b5c57648f..632ebf849 100644 --- a/features/environment.py +++ b/features/environment.py @@ -38,14 +38,6 @@ def before_all(context): ) os.environ.setdefault("BEHAVE_TESTING", "true") - # Use the actual Plandex repository if it exists - plandex_path = Path("/app/plandex") - if plandex_path.exists(): - context.plandex_root = plandex_path - else: - # Tests will skip if Plandex directory doesn't exist - context.plandex_root = None - # Set up mock AI provider for all tests try: from cleveragents.application.container import override_providers diff --git a/features/implicit_behaviors.feature b/features/implicit_behaviors.feature deleted file mode 100644 index 598016799..000000000 --- a/features/implicit_behaviors.feature +++ /dev/null @@ -1,66 +0,0 @@ -@discovery -Feature: Implicit Behaviors Extraction - As a developer migrating from Go to Python - I want to extract implicit runtime behaviors from Plandex - So that I can replicate them accurately in CleverAgents - - Background: - Given a Plandex repository with Go source code - And an implicit behavior extractor initialized with the repository - - Scenario: Extract auto-context loading behaviors - When I extract implicit behaviors from the codebase - Then the results should contain auto-context behaviors - And each auto-context behavior should have triggers listed - And each behavior should have Python migration considerations - - Scenario: Extract resource locking patterns - When I extract implicit behaviors from the codebase - Then the results should contain locking behaviors - And locking behaviors should reference mutex or file lock patterns - And Python alternatives should mention threading or asyncio locks - - Scenario: Extract retry and backoff patterns - When I extract implicit behaviors from the codebase - Then the results should contain retry behaviors - And retry behaviors should mention exponential backoff - And Python considerations should suggest tenacity or backoff libraries - - Scenario: Extract validation patterns - When I extract implicit behaviors from the codebase - Then the results should contain validation behaviors - And validation behaviors should reference input checks - And Python notes should mention pydantic or marshmallow - - Scenario: Extract concurrency patterns - When I extract implicit behaviors from the codebase - Then the results should contain concurrency behaviors - And concurrency behaviors should reference goroutines or channels - And Python alternatives should mention asyncio or threading - - Scenario: Extract streaming behaviors - When I extract implicit behaviors from the codebase - Then the results should contain streaming behaviors - And streaming behaviors should reference WebSocket or SSE - And Python considerations should mention aiohttp - - Scenario: Generate sequence diagrams - When I extract implicit behaviors from the codebase - Then the results should include sequence diagrams - And there should be a diagram for auto-context loading - And there should be a diagram for retry with backoff - And there should be a diagram for git locking - - Scenario: Save behavior documentation - When I extract implicit behaviors from the codebase - And I save the results to "build/test_output/behaviors" - Then a JSON file should be created with the behaviors - And a YAML file should be created with the behaviors - And a Markdown documentation file should be created - And the documentation should include all behavior categories - - Scenario: Collect Python migration notes - When I extract implicit behaviors from the codebase - Then the statistics should include Python migration considerations - And the migration notes should be unique - And the notes should cover asyncio, threading, and validation libraries diff --git a/features/server_endpoints.feature b/features/server_endpoints.feature deleted file mode 100644 index a8e2c5474..000000000 --- a/features/server_endpoints.feature +++ /dev/null @@ -1,53 +0,0 @@ -Feature: Server Endpoint Extraction - As a developer migrating Plandex to CleverAgents - I want to extract server API endpoints from the Go codebase - So that I can ensure API parity in the Python implementation - - Background: - Given the Plandex Go codebase is available - And the server endpoint extractor is initialized - - Scenario: Extract server endpoints from Go source - When I run the server endpoint extraction - Then the extraction should succeed - And at least 80 endpoints should be extracted - And the inventory should include endpoint metadata - And the server inventory can be saved - - Scenario: Validate extracted endpoint structure - Given the server endpoints have been extracted - When I check the endpoint structure - Then each endpoint should have a path - And each endpoint should have a method - And each endpoint should have a handler - And streaming endpoints should be identified - - Scenario: Export endpoints in multiple formats - When I save the server endpoint inventory - Then a YAML file should be created at "docs/reference/server_endpoints.yaml" - And a JSON file should be created at "docs/reference/server_endpoints.json" - And an OpenAPI spec should be created at "docs/reference/server_api.yaml" - And all files should contain consistent data - - Scenario: Categorize endpoints by functionality - Given the server endpoints have been extracted - When I check endpoint categorization - Then endpoints should be grouped by category - And categories should include Authentication - And categories should include Plans - And categories should include Projects - And categories should include Models - - Scenario: Extract path parameters - Given the server endpoints have been extracted - When I check for path parameters - Then endpoints with path parameters should be identified - And path parameter names should be extracted - And parameters like planId and projectId should be found - - Scenario: Identify authentication requirements - Given the server endpoints have been extracted - When I check authentication requirements - Then public endpoints should be identified - And protected endpoints should be identified - And health and version endpoints should be public \ No newline at end of file diff --git a/features/shell_assets.feature b/features/shell_assets.feature deleted file mode 100644 index 4330bb20e..000000000 --- a/features/shell_assets.feature +++ /dev/null @@ -1,58 +0,0 @@ -@discovery -Feature: Shell Asset Extraction - As a developer migrating from Plandex to CleverAgents - I need to extract and catalog shell scripts from the Go codebase - So that I can create Python replacements and understand dependencies - - Background: - Given the Plandex Go repository exists - And the ShellAssetExtractor is initialized - - Scenario: Extract shell scripts from repository - When I run the shell asset extraction - Then shell scripts should be discovered - And each script should have metadata extracted - - Scenario: Analyze start_local.sh script - When I extract shell assets - Then the start_local.sh script should be found - And it should be marked as requiring Docker - And it should be marked as requiring Git - And it should be suggested for Python replacement - - Scenario: Identify environment variables in scripts - When I extract shell assets - Then environment variables should be identified - And each variable should be mapped to its scripts - - Scenario: Detect script dependencies - When I extract shell assets - Then scripts requiring Docker should be identified - And scripts requiring Git should be identified - And command dependencies should be captured - - Scenario: Generate Python wrappers for scripts - When I extract shell assets - And I save the catalog with wrappers - Then Python wrapper files should be created - And wrappers should include documentation - And wrappers should preserve environment variable handling - - Scenario: Save shell asset catalog - When I extract shell assets - And I save the catalog - Then a YAML catalog file should be created - And a JSON catalog file should be created - And both catalog files should contain the same data - - Scenario: Identify idempotent scripts - When I extract shell assets - Then idempotent scripts should be marked - And scripts with mkdir -p should be idempotent - And scripts with test checks should be idempotent - - Scenario: Categorize scripts by purpose - When I extract shell assets - Then test scripts should be identified - And development scripts should be identified - And code generation scripts should be identified \ No newline at end of file diff --git a/features/steps/cloud_features_steps.py b/features/steps/cloud_features_steps.py deleted file mode 100644 index 8fcc814bc..000000000 --- a/features/steps/cloud_features_steps.py +++ /dev/null @@ -1,287 +0,0 @@ -"""Step definitions for cloud features identification.""" - -import json -from pathlib import Path - -from behave import given, then, when - -from cleveragents.discovery.cloud_features import CloudFeaturesExtractor - - -@given("the cloud features extractor is initialized") -def step_init_cloud_extractor(context): - """Initialize the cloud features extractor.""" - plandex_dir = Path(__file__).parent.parent.parent / "plandex" - context.cloud_extractor = CloudFeaturesExtractor(plandex_dir) - - -@when("I run the cloud features extraction") -def step_run_cloud_extraction(context): - """Run the cloud features extraction.""" - context.cloud_results = context.cloud_extractor.extract_all() - - -@when("I scan for billing features") -def step_scan_billing_features(context): - """Scan for billing features.""" - context.cloud_extractor._scan_billing_features() - context.billing_features = { - k: v - for k, v in context.cloud_extractor.cloud_features.items() - if v.get("category") == "billing" - } - - -@when("I scan for telemetry features") -def step_scan_telemetry_features(context): - """Scan for telemetry features.""" - context.cloud_extractor._scan_telemetry_features() - context.telemetry_features = { - k: v - for k, v in context.cloud_extractor.cloud_features.items() - if v.get("category") == "telemetry" - } - - -@when("I scan for managed auth features") -def step_scan_auth_features(context): - """Scan for managed authentication features.""" - context.cloud_extractor._scan_auth_features() - context.auth_features = { - k: v - for k, v in context.cloud_extractor.cloud_features.items() - if v.get("category") == "managed_auth" - } - - -@when("I extract cloud features and generate strategies") -def step_extract_and_generate_strategies(context): - """Extract features and generate replacement strategies.""" - context.cloud_results = context.cloud_extractor.extract_all() - context.replacement_strategies = context.cloud_results["replacements"] - - -@when("I extract all cloud features") -def step_extract_all_cloud_features(context): - """Extract all cloud features.""" - context.cloud_results = context.cloud_extractor.extract_all() - - -@given("I have identified cloud features") -def step_have_cloud_features(context): - """Ensure cloud features are identified.""" - if not hasattr(context, "cloud_results"): - context.cloud_results = context.cloud_extractor.extract_all() - - -@when("I save the cloud features results") -def step_save_cloud_results(context): - """Save cloud features results.""" - output_dir = Path("build/test_output/cloud") - context.json_file, context.yaml_file = context.cloud_extractor.save_results( - output_dir - ) - - -@then("I should identify features in all categories") -def step_check_cloud_categories(context): - """Check that features are found in multiple categories.""" - features = context.cloud_results["cloud_features"] - categories = set(f.get("category") for f in features.values()) - assert len(categories) >= 5, f"Expected multiple categories, got {categories}" - - -@then("each feature should have an action specified") -def step_check_feature_actions(context): - """Check that each feature has an action.""" - features = context.cloud_results["cloud_features"] - for feat_id, feature in features.items(): - assert "action" in feature, f"Missing action in {feat_id}" - assert feature["action"] in ["remove", "replace", "defer"], ( - f"Invalid action in {feat_id}" - ) - - -@then("each feature should have a priority assigned") -def step_check_feature_priorities(context): - """Check that each feature has a priority.""" - features = context.cloud_results["cloud_features"] - for feat_id, feature in features.items(): - assert "priority" in feature, f"Missing priority in {feat_id}" - assert feature["priority"] in ["high", "medium", "low"], ( - f"Invalid priority in {feat_id}" - ) - - -@then("the statistics should include feature counts") -def step_check_cloud_statistics(context): - """Check cloud feature statistics.""" - stats = context.cloud_results["statistics"] - assert "total_features" in stats - assert stats["total_features"] > 0 - assert "by_category" in stats - assert "by_action" in stats - assert "by_priority" in stats - - -@then("I should find {feature_id} feature") -def step_find_cloud_feature(context, feature_id): - """Check that a specific feature exists.""" - # Try to find the feature in the appropriate context attribute - if hasattr(context, "billing_features") and feature_id in context.billing_features: - return - if ( - hasattr(context, "telemetry_features") - and feature_id in context.telemetry_features - ): - return - if hasattr(context, "auth_features") and feature_id in context.auth_features: - return - - # If not found in any specific category, check all features - if hasattr(context, "cloud_extractor"): - features = context.cloud_extractor.cloud_features - assert feature_id in features, f"Feature {feature_id} not found" - else: - raise AssertionError(f"Feature {feature_id} not found in any category") - - -@then("each billing feature should have replacement strategy") -def step_check_billing_replacements(context): - """Check billing features have replacements.""" - for feat_id, feature in context.billing_features.items(): - assert "replacement" in feature, f"Missing replacement in {feat_id}" - - -@then("telemetry should default to opt-in local alternatives") -def step_check_telemetry_opt_in(context): - """Check telemetry is opt-in.""" - for feat_id, feature in context.telemetry_features.items(): - if "replacement" in feature: - replacement = feature["replacement"].lower() - assert "opt-in" in replacement or "local" in replacement, ( - f"Telemetry {feat_id} should be opt-in/local" - ) - - -@then("auth features should have local replacements") -def step_check_auth_replacements(context): - """Check auth features have local replacements.""" - for feat_id, feature in context.auth_features.items(): - assert "replacement" in feature, f"Missing replacement in {feat_id}" - assert "local" in feature["replacement"].lower(), ( - f"Auth feature {feat_id} should have local replacement" - ) - - -@then("features should be categorized by action") -def step_check_action_categories(context): - """Check features are categorized by action.""" - assert "remove" in context.replacement_strategies - assert "replace" in context.replacement_strategies - - -@then("remove features should be listed") -def step_check_remove_features(context): - """Check remove features are listed.""" - remove_list = context.replacement_strategies["remove"] - assert isinstance(remove_list, list) - # We should have at least some features to remove - assert len(remove_list) > 0 - - -@then("replace features should have alternatives") -def step_check_replace_alternatives(context): - """Check replace features have alternatives.""" - replace_list = context.replacement_strategies["replace"] - for item in replace_list: - assert "replacement" in item - assert item["replacement"] != "None" - - -@then("strategies should be sorted by priority") -def step_check_strategy_sorting(context): - """Check strategies are sorted by priority.""" - for action_list in context.replacement_strategies.values(): - if len(action_list) > 1: - priorities = {"high": 0, "medium": 1, "low": 2} - prev_priority = -1 - for item in action_list: - curr_priority = priorities.get(item["priority"], 3) - assert curr_priority >= prev_priority, ( - "Strategies not sorted by priority" - ) - prev_priority = curr_priority - - -@then("a JSON file should be created with feature data") -def step_check_cloud_json_file(context): - """Check JSON file creation.""" - assert context.json_file.exists() - with open(context.json_file) as f: - data = json.load(f) - assert "cloud_features" in data - assert "replacements" in data - - -@then("a YAML file should be created with feature data") -def step_check_cloud_yaml_file(context): - """Check YAML file creation.""" - assert context.yaml_file.exists() - - -@then("a cloud features Markdown documentation should be generated") -def step_check_cloud_markdown_doc(context): - """Check Markdown documentation.""" - md_file = context.json_file.parent / "cloud_features.md" - assert md_file.exists(), f"Markdown file {md_file} does not exist" - content = md_file.read_text() - assert "# Cloud-Only Features Analysis" in content - - -@then("the documentation should include replacement strategies") -def step_check_cloud_doc_strategies(context): - """Check documentation includes strategies.""" - md_file = context.json_file.parent / "cloud_features.md" - assert md_file.exists() - content = md_file.read_text() - assert "Replacement Strategies" in content - - -@then("the statistics should include total features") -def step_check_total_features(context): - """Check total features statistic.""" - stats = context.cloud_results["statistics"] - assert stats["total_features"] > 0 - - -@then("the statistics should count features by category") -def step_check_features_by_category(context): - """Check features by category statistic.""" - stats = context.cloud_results["statistics"] - assert len(stats["by_category"]) > 0 - - -@then("the statistics should count features by action") -def step_check_features_by_action(context): - """Check features by action statistic.""" - stats = context.cloud_results["statistics"] - assert stats["by_action"]["remove"] >= 0 - assert stats["by_action"]["replace"] >= 0 - - -@then("the statistics should count features by priority") -def step_check_features_by_priority(context): - """Check features by priority statistic.""" - stats = context.cloud_results["statistics"] - assert stats["by_priority"]["high"] >= 0 - assert stats["by_priority"]["medium"] >= 0 - assert stats["by_priority"]["low"] >= 0 - - -@then("the statistics should count affected Go files") -def step_check_affected_files(context): - """Check affected Go files statistic.""" - stats = context.cloud_results["statistics"] - assert "go_files_affected" in stats - assert stats["go_files_affected"] > 0 diff --git a/features/steps/data_contracts_steps.py b/features/steps/data_contracts_steps.py deleted file mode 100644 index 3200c92c6..000000000 --- a/features/steps/data_contracts_steps.py +++ /dev/null @@ -1,349 +0,0 @@ -"""Step definitions for data contract extraction features.""" - -import json -import tempfile -from pathlib import Path - -from behave import given, then, when - -from cleveragents.discovery.data_contracts import DataContractExtractor - - -@given('the Plandex repository exists at "../plandex"') -def step_plandex_repository_exists(context): - """Verify Plandex repository exists.""" - # Use the Plandex directory from environment.py - context.plandex_dir = getattr(context, "plandex_root", Path("/app/plandex")) - assert context.plandex_dir.exists(), ( - f"Plandex directory not found: {context.plandex_dir}" - ) - - -@given("the shared directory contains Go contract files") -def step_shared_directory_exists(context): - """Verify shared directory exists with Go files.""" - context.plandex_dir = Path(context.plandex_dir) - shared_dir = context.plandex_dir / "app" / "shared" - assert shared_dir.exists(), f"Shared directory not found: {shared_dir}" - - go_files = list(shared_dir.glob("*.go")) - assert len(go_files) > 0, "No Go files found in shared directory" - context.go_file_count = len(go_files) - - -@when("I run the data contract extractor") -def step_run_contract_extractor(context): - """Run the data contract extraction.""" - context.extractor = DataContractExtractor(context.plandex_dir) - context.contracts = context.extractor.extract_all() - assert context.contracts, "No contracts extracted" - - -@then("contracts should be extracted from multiple modules") -def step_verify_multiple_modules(context): - """Verify contracts from multiple modules.""" - # For mock data, just check that we got at least one module - assert len(context.contracts) >= 1, ( - f"Expected at least one module, got {len(context.contracts)}" - ) - - -@then("each contract should contain structs with fields") -def step_verify_structs_with_fields(context): - """Verify contracts contain structs with fields.""" - structs_found = False - for module_name, contract in context.contracts.items(): - if contract.structs: - structs_found = True - for struct in contract.structs: - assert struct.name, f"Struct without name in {module_name}" - # At least some structs should have fields - if struct.fields: - assert len(struct.fields) > 0 - - assert structs_found, "No structs found in any contract" - - -@then("struct fields should have type information") -def step_verify_field_types(context): - """Verify struct fields have type information.""" - fields_checked = 0 - for contract in context.contracts.values(): - for struct in contract.structs: - for field in struct.fields: - assert field.name, "Field without name" - assert field.type_name, f"Field {field.name} without type" - fields_checked += 1 - - # For mock data, at least one field should be checked - assert fields_checked >= 1, f"No fields found: {fields_checked}" - - -@then("JSON tags should be preserved") -def step_verify_json_tags(context): - """Verify JSON tags are extracted.""" - json_tags_found = False - for contract in context.contracts.values(): - for struct in contract.structs: - for field in struct.fields: - if field.json_tag: - json_tags_found = True - break - if json_tags_found: - break - if json_tags_found: - break - - # For mock data, it's okay if no JSON tags are found - # Just pass the test - - -@then("enums should be identified from const blocks") -def step_verify_enums(context): - """Verify enums are extracted.""" - for contract in context.contracts.values(): - if contract.enums: - break - - # Note: Enums might not be present in all Go code - # So we just check the extraction doesn't fail - assert True, "Enum extraction completed" - - -@then("type aliases should be extracted") -def step_verify_type_aliases(context): - """Verify type aliases are extracted.""" - for contract in context.contracts.values(): - if contract.type_aliases: - for alias in contract.type_aliases: - assert alias.name, "Type alias without name" - assert alias.underlying_type, ( - f"Type alias {alias.name} without underlying type" - ) - break - - # Type aliases might not be present in all modules - assert True, "Type alias extraction completed" - - -@then("each enum should have a list of values") -def step_verify_enum_values(context): - """Verify enums have values.""" - for contract in context.contracts.values(): - for enum in contract.enums: - assert enum.name, "Enum without name" - assert isinstance(enum.values, list), f"Enum {enum.name} values not a list" - if enum.values: # If enum has values, verify them - assert all(v for v in enum.values), f"Empty value in enum {enum.name}" - - -@when("I generate Python stubs") -def step_generate_python_stubs(context): - """Generate Python dataclass stubs.""" - context.temp_dir = tempfile.mkdtemp() - context.output_dir = Path(context.temp_dir) - context.extractor.save_contracts(context.output_dir) - context.stubs_dir = context.output_dir / "stubs" - - -@then("Python files should be created for each module") -def step_verify_python_files(context): - """Verify Python stub files are created.""" - assert context.stubs_dir.exists(), "Stubs directory not created" - - py_files = list(context.stubs_dir.glob("*.py")) - assert len(py_files) > 0, "No Python files generated" - - # Should have roughly same number of Python files as contracts with structs - contracts_with_structs = sum( - 1 for c in context.contracts.values() if c.structs or c.enums or c.type_aliases - ) - assert len(py_files) >= contracts_with_structs * 0.8, ( - f"Expected ~{contracts_with_structs} Python files, got {len(py_files)}" - ) - - -@then("dataclasses should match Go struct definitions") -def step_verify_dataclasses(context): - """Verify generated dataclasses match Go structs.""" - for py_file in context.stubs_dir.glob("*.py"): - content = py_file.read_text() - - # Check for dataclass imports - assert "from dataclasses import" in content, ( - f"No dataclass import in {py_file.name}" - ) - - # Check for class definitions - if "@dataclass" in content: - assert "class " in content, f"No class definitions in {py_file.name}" - - -@then("field types should be converted to Python types") -def step_verify_python_types(context): - """Verify Go types are converted to Python types.""" - for py_file in context.stubs_dir.glob("*.py"): - content = py_file.read_text() - - # Check for Python type conversions - if "class " in content: - # Should see Python types, not Go types - assert ( - "str" in content - or "int" in content - or "float" in content - or "bool" in content - ), f"No Python types found in {py_file.name}" - - # Should not see raw Go types in field definitions (allow in comments/strings) - # Look for patterns like ": string" which would indicate unconverted types - import re - - field_pattern = re.compile(r"^\s+\w+:\s+string\s*(?:=|$)", re.MULTILINE) - matches = field_pattern.findall(content) - assert len(matches) == 0, ( - f"Unconverted Go 'string' type found in field definitions in {py_file.name}" - ) - - -@then("optional fields should use Optional type hints") -def step_verify_optional_types(context): - """Verify optional fields use Optional.""" - optional_found = False - for py_file in context.stubs_dir.glob("*.py"): - content = py_file.read_text() - if "Optional[" in content: - optional_found = True - break - - assert optional_found, "No Optional type hints found in any stub file" - - -@when("I generate example fixtures") -def step_generate_fixtures(context): - """Generate example JSON fixtures.""" - if not hasattr(context, "output_dir"): - context.temp_dir = tempfile.mkdtemp() - context.output_dir = Path(context.temp_dir) - context.extractor.save_contracts(context.output_dir) - - context.fixtures_dir = context.output_dir / "fixtures" - - -@then("JSON fixtures should be created for each struct") -def step_verify_json_fixtures(context): - """Verify JSON fixture files are created.""" - assert context.fixtures_dir.exists(), "Fixtures directory not created" - - json_files = list(context.fixtures_dir.glob("*.json")) - assert len(json_files) > 0, "No JSON fixtures generated" - - -@then("fixtures should contain valid example data") -def step_verify_fixture_data(context): - """Verify fixtures contain valid JSON data.""" - for json_file in context.fixtures_dir.glob("*.json"): - content = json_file.read_text() - try: - data = json.loads(content) - assert isinstance(data, dict), f"Fixture {json_file.name} not a JSON object" - # Should have at least some fields - if data: - assert len(data) > 0, f"Empty fixture in {json_file.name}" - except json.JSONDecodeError as e: - raise AssertionError(f"Invalid JSON in {json_file.name}: {e}") - - -@then("field names should use JSON tags when present") -def step_verify_json_tag_usage(context): - """Verify fixtures use JSON tags for field names.""" - # Check at least one fixture for proper JSON tag usage - json_files = list(context.fixtures_dir.glob("*.json")) - if json_files: - for json_file in json_files[:5]: # Check first 5 files - content = json_file.read_text() - data = json.loads(content) - - # Common JSON tag patterns (camelCase, snake_case) - for key in data: - # Most JSON tags will be lowercase or camelCase - if key and key[0].islower(): - return # Found at least one properly formatted field - - # If no fixtures or no lowercase fields, that's okay - assert True, "JSON tag verification completed" - - -@when("I save the contracts") -def step_save_contracts(context): - """Save contracts to files.""" - if not hasattr(context, "output_dir"): - context.temp_dir = tempfile.mkdtemp() - context.output_dir = Path(context.temp_dir) - - context.extractor.save_contracts(context.output_dir) - context.json_file = context.output_dir / "data_contracts.json" - context.yaml_file = context.output_dir / "data_contracts.yaml" - - -@then("a JSON file should be created with all contracts") -def step_verify_json_output(context): - """Verify JSON output file.""" - assert context.json_file.exists(), "JSON file not created" - - with open(context.json_file) as f: - data = json.load(f) - assert isinstance(data, dict), "JSON root should be a dictionary" - assert len(data) > 0, "JSON file is empty" - - # Verify structure - for module_name, contract_data in data.items(): - assert "structs" in contract_data, f"No structs in {module_name}" - assert "enums" in contract_data, f"No enums in {module_name}" - assert "type_aliases" in contract_data, f"No type_aliases in {module_name}" - - -@then("a YAML file should be created with all contracts") -def step_verify_yaml_output(context): - """Verify YAML output file.""" - try: - import yaml - - assert context.yaml_file.exists(), "YAML file not created" - - with open(context.yaml_file) as f: - data = yaml.safe_load(f) - assert isinstance(data, dict), "YAML root should be a dictionary" - assert len(data) > 0, "YAML file is empty" - except ImportError: - # PyYAML not installed, that's okay - pass - - -@then("both files should contain the same data structure") -def step_verify_json_yaml_match(context): - """Verify JSON and YAML contain same data.""" - try: - import yaml - - if context.json_file.exists() and context.yaml_file.exists(): - with open(context.json_file) as f: - json_data = json.load(f) - - with open(context.yaml_file) as f: - yaml_data = yaml.safe_load(f) - - # Compare keys - assert json_data.keys() == yaml_data.keys(), ( - "JSON and YAML have different keys" - ) - - # Compare structure (not deep equality due to potential formatting differences) - for key in json_data: - assert key in yaml_data, f"Key {key} missing from YAML" - assert type(json_data[key]) == type(yaml_data[key]), ( - f"Type mismatch for {key}" - ) - except ImportError: - # PyYAML not installed, skip this check - pass diff --git a/features/steps/discovery_module_steps.py b/features/steps/discovery_module_steps.py deleted file mode 100644 index 033447d5c..000000000 --- a/features/steps/discovery_module_steps.py +++ /dev/null @@ -1,135 +0,0 @@ -"""Step definitions for discovery module tests.""" - -from behave import given, then, when - -from cleveragents.discovery.cli_inventory import CLIInventoryExtractor, main - - -@when("I import the discovery module") -def step_import_discovery_module(context): - """Import the discovery module.""" - try: - import cleveragents.discovery - - context.discovery_module = cleveragents.discovery - context.import_success = True - except ImportError as e: - context.import_error = e - context.import_success = False - - -@then("it should have CLIInventoryExtractor available") -def step_check_cli_extractor_available(context): - """Check CLIInventoryExtractor is available.""" - assert context.import_success, ( - f"Import failed: {getattr(context, 'import_error', 'Unknown')}" - ) - assert hasattr(context.discovery_module, "CLIInventoryExtractor") - - -@when("I run the discovery CLI inventory main") -def step_run_discovery_main(context): - """Run the main function from cli_inventory.""" - try: - context.main_result = main() - context.main_success = True - except Exception as e: - context.main_error = e - context.main_success = False - - -@then("it should extract and save the inventory") -def step_check_main_extraction(context): - """Check that main extracted and saved inventory.""" - assert context.main_success, ( - f"Main failed: {getattr(context, 'main_error', 'Unknown')}" - ) - assert context.main_result is not None - assert "statistics" in context.main_result - assert context.main_result["statistics"]["total_commands"] > 0 - - -@given("a CLI inventory extractor instance") -def step_create_extractor_instance(context): - """Create a CLI inventory extractor instance.""" - context.extractor = CLIInventoryExtractor() - - -@when('I convert "{var_name}" to command name') -def step_convert_var_to_command(context, var_name): - """Convert Go variable name to command name.""" - context.converted_name = context.extractor._var_to_cmd_name(var_name) - - -@then('the converted name should be "{expected}"') -def step_check_converted_name(context, expected): - """Check the converted name matches expected.""" - assert context.converted_name == expected, ( - f"Expected '{expected}', got '{context.converted_name}'" - ) - - -@when("I build the command hierarchy") -def step_build_hierarchy(context): - """Build the command hierarchy.""" - # Extract commands first - context.extractor.extract_all() - context.hierarchy = context.extractor._build_command_hierarchy() - - -@then("it should return a hierarchical structure") -def step_check_hierarchy(context): - """Check hierarchy structure.""" - assert context.hierarchy is not None - assert "root" in context.hierarchy - assert "subcommands" in context.hierarchy["root"] - - -@when("I gather statistics about extracted commands") -def step_gather_statistics(context): - """Gather statistics.""" - # Extract commands first - context.extractor.extract_all() - context.statistics = context.extractor._gather_statistics() - - -@then("statistics should include total_commands") -def step_check_stats_total(context): - """Check total_commands in statistics.""" - assert "total_commands" in context.statistics - - -@then("statistics should include commands_with_aliases") -def step_check_stats_aliases(context): - """Check commands_with_aliases in statistics.""" - assert "commands_with_aliases" in context.statistics - - -@then("statistics should include commands_with_flags") -def step_check_stats_flags(context): - """Check commands_with_flags in statistics.""" - assert "commands_with_flags" in context.statistics - - -@when("I extract additional metadata") -def step_extract_metadata(context): - """Extract additional metadata.""" - context.metadata = context.extractor._extract_additional_metadata() - - -@then("metadata should include repl_commands") -def step_check_metadata_repl(context): - """Check repl_commands in metadata.""" - assert "repl_commands" in context.metadata - - -@then("metadata should include shortcuts") -def step_check_metadata_shortcuts(context): - """Check shortcuts in metadata.""" - assert "shortcuts" in context.metadata - - -@then("metadata should include environment_variables") -def step_check_metadata_env(context): - """Check environment_variables in metadata.""" - assert "environment_variables" in context.metadata diff --git a/features/steps/discovery_run_all_steps.py b/features/steps/discovery_run_all_steps.py deleted file mode 100644 index 1c5eebfc4..000000000 --- a/features/steps/discovery_run_all_steps.py +++ /dev/null @@ -1,63 +0,0 @@ -"""Step definitions for run_all discovery script tests.""" - -import io -from contextlib import redirect_stdout - -from behave import then, when - - -@when("I import the run_all module from discovery") -def step_import_run_all(context): - """Import the run_all module.""" - try: - from cleveragents.discovery import run_all - - context.run_all_module = run_all - context.import_success = True - except ImportError as e: - context.import_error = e - context.import_success = False - - -@then("it should have a main function") -def step_check_main_function(context): - """Check that run_all has a main function.""" - assert context.import_success, ( - f"Import failed: {getattr(context, 'import_error', 'Unknown')}" - ) - assert hasattr(context.run_all_module, "main") - - -@when("I execute the run_all main function") -def step_execute_run_all_main(context): - """Execute the run_all main function.""" - try: - from cleveragents.discovery.run_all import main - - # Capture output - captured_output = io.StringIO() - with redirect_stdout(captured_output): - main() - - context.run_all_output = captured_output.getvalue() - context.run_all_success = True - except Exception as e: - context.run_all_error = e - context.run_all_success = False - - -@then("it should run successfully") -def step_check_run_all_success(context): - """Check that run_all executed successfully.""" - assert context.run_all_success, ( - f"Run all failed: {getattr(context, 'run_all_error', 'Unknown')}" - ) - assert context.run_all_output is not None - - -@then("it should extract CLI inventory") -def step_check_cli_extracted(context): - """Check that CLI inventory was extracted.""" - assert "Extracting CLI Command Inventory" in context.run_all_output - assert "✓ Extracted" in context.run_all_output - assert "commands" in context.run_all_output diff --git a/features/steps/discovery_steps.py b/features/steps/discovery_steps.py deleted file mode 100644 index 5e3c3035d..000000000 --- a/features/steps/discovery_steps.py +++ /dev/null @@ -1,255 +0,0 @@ -"""Step definitions for discovery feature tests.""" - -import json -from pathlib import Path - -import yaml -from behave import given, then, when - -from cleveragents.discovery.cli_inventory import CLIInventoryExtractor - - -@given("the Plandex Go codebase is available") -def step_plandex_codebase_available(context): - """Check that the Plandex Go codebase exists. - - Falls back to a lightweight mock directory when the real Plandex repo - isn't present so the Behave scenarios can still run locally. - """ - # Prefer the path configured by environment.py when available - plandex_dir = getattr(context, "plandex_root", None) or Path("/app/plandex") - - if not plandex_dir.exists(): - # Create a minimal placeholder so downstream steps have a valid path - plandex_dir = Path("/app/build/test_output/mock_plandex") - plandex_dir.mkdir(parents=True, exist_ok=True) - - assert plandex_dir.exists(), f"Plandex directory not found at {plandex_dir}" - context.plandex_dir = plandex_dir - - -@given("the CLI inventory extractor is initialized") -def step_init_cli_extractor(context): - """Initialize the CLI inventory extractor.""" - context.extractor = CLIInventoryExtractor(context.plandex_dir) - assert context.extractor is not None - - -@when("I run the CLI inventory extraction") -def step_run_extraction(context): - """Run the CLI inventory extraction.""" - try: - context.inventory = context.extractor.extract_all() - context.extraction_succeeded = True - except Exception as e: - context.extraction_error = e - context.extraction_succeeded = False - - -@then("the extraction should succeed") -def step_extraction_succeeds(context): - """Verify the extraction succeeded.""" - assert context.extraction_succeeded, ( - f"Extraction failed: {getattr(context, 'extraction_error', 'Unknown error')}" - ) - # Check for either inventory (CLI) or server_inventory (server endpoints) - assert hasattr(context, "inventory") or hasattr(context, "server_inventory") - - -@then("at least {count:d} commands should be extracted") -def step_minimum_commands_extracted(context, count): - """Verify minimum number of commands extracted.""" - total_commands = len(context.inventory.get("commands", [])) - # For mock data, just check that we got at least 1 command - assert total_commands >= 1, f"Expected at least 1 command, but got {total_commands}" - """Verify minimum number of commands extracted.""" - num_commands = context.inventory["statistics"]["total_commands"] - assert num_commands >= count, ( - f"Expected at least {count} commands, got {num_commands}" - ) - - -@then("the inventory should contain a root command") -def step_inventory_has_root(context): - """Verify the inventory contains a root command.""" - assert context.inventory.get("root") is not None, ( - "No root command found in inventory" - ) - - -@then("the inventory should include command metadata") -def step_inventory_has_metadata(context): - """Verify the inventory includes metadata.""" - assert "commands" in context.inventory, "No commands section in inventory" - assert "hierarchy" in context.inventory, "No hierarchy section in inventory" - assert "metadata" in context.inventory, "No metadata section in inventory" - assert "statistics" in context.inventory, "No statistics section in inventory" - - -@then("the inventory files should be saved") -def step_inventory_files_saved(context): - """Verify inventory files are saved.""" - output_files = context.extractor.save_inventory() - assert output_files["yaml"].exists(), f"YAML file not found: {output_files['yaml']}" - assert output_files["json"].exists(), f"JSON file not found: {output_files['json']}" - context.output_files = output_files - - -@given("the CLI inventory has been extracted") -def step_inventory_extracted(context): - """Ensure inventory is extracted.""" - if not hasattr(context, "extractor"): - context.extractor = CLIInventoryExtractor() - if not hasattr(context, "inventory"): - context.inventory = context.extractor.extract_all() - - -@when("I check the command structure") -def step_check_command_structure(context): - """Check the structure of extracted commands.""" - context.commands = context.inventory.get("commands", {}) - assert len(context.commands) > 0, "No commands found in inventory" - - -@then("each command should have a name") -def step_commands_have_names(context): - """Verify each command has a name.""" - for cmd_name, cmd_data in context.commands.items(): - assert cmd_data.get("name"), f"Command {cmd_name} has no name" - - -@then("each command should have a file_path") -def step_commands_have_file_paths(context): - """Verify each command has a file path.""" - for cmd_name, cmd_data in context.commands.items(): - assert cmd_data.get("file_path"), f"Command {cmd_name} has no file_path" - - -@then("auth requirements should be detected") -def step_auth_requirements_detected(context): - """Verify auth requirements are detected.""" - auth_required = context.inventory["statistics"]["auth_required"] - assert auth_required > 0, "No commands with auth requirements detected" - - -@then("project requirements should be detected") -def step_project_requirements_detected(context): - """Verify project requirements are detected.""" - project_required = context.inventory["statistics"]["project_required"] - assert project_required > 0, "No commands with project requirements detected" - - -@when("I save the CLI inventory") -def step_save_inventory(context): - """Save the CLI inventory.""" - if not hasattr(context, "extractor"): - context.extractor = CLIInventoryExtractor() - if not hasattr(context, "inventory"): - context.inventory = context.extractor.extract_all() - context.output_files = context.extractor.save_inventory() - - -@then('a YAML file should be created at "{path}"') -def step_yaml_file_created(context, path): - """Verify YAML file is created at specified path.""" - yaml_path = Path("/app") / path - assert yaml_path.exists(), f"YAML file not found at {yaml_path}" - - -@then('a JSON file should be created at "{path}"') -def step_json_file_created(context, path): - """Verify JSON file is created at specified path.""" - json_path = Path("/app") / path - assert json_path.exists(), f"JSON file not found at {json_path}" - - -@then("both files should contain the same data") -def step_files_contain_same_data(context): - """Verify YAML and JSON files contain the same data.""" - yaml_path = context.output_files["yaml"] - json_path = context.output_files["json"] - - with open(yaml_path) as f: - yaml_data = yaml.safe_load(f) - - with open(json_path) as f: - json_data = json.load(f) - - assert yaml_data == json_data, "YAML and JSON files contain different data" - - -@when("I check for command aliases") -def step_check_command_aliases(context): - """Check for command aliases in the inventory.""" - if not hasattr(context, "commands"): - context.commands = context.inventory.get("commands", {}) - - context.commands_with_aliases = [ - cmd - for cmd in context.commands.values() - if cmd.get("aliases") and len(cmd["aliases"]) > 0 - ] - - -@then("commands with aliases should be identified") -def step_aliases_identified(context): - """Verify commands with aliases are identified.""" - # The current extractor may not capture all aliases yet, so we'll be lenient - # Just verify the structure is there - assert isinstance(context.commands_with_aliases, list), "Aliases check failed" - - -@then("the aliases should be properly formatted") -def step_aliases_formatted(context): - """Verify aliases are properly formatted.""" - for cmd in context.commands_with_aliases: - assert isinstance(cmd["aliases"], list), f"Aliases for {cmd['name']} not a list" - for alias in cmd["aliases"]: - assert isinstance(alias, str), ( - f"Alias {alias} for {cmd['name']} not a string" - ) - - -@when("I check for command flags") -def step_check_command_flags(context): - """Check for command flags in the inventory.""" - if not hasattr(context, "commands"): - context.commands = context.inventory.get("commands", {}) - - context.commands_with_flags = [ - cmd - for cmd in context.commands.values() - if cmd.get("flags") and len(cmd["flags"]) > 0 - ] - - -@then("commands with flags should be identified") -def step_flags_identified(context): - """Verify commands with flags are identified.""" - num_with_flags = len(context.commands_with_flags) - stats_with_flags = context.inventory["statistics"]["commands_with_flags"] - assert num_with_flags == stats_with_flags, ( - f"Flag count mismatch: {num_with_flags} vs {stats_with_flags}" - ) - - -@then("flag metadata should include name and type") -def step_flag_metadata(context): - """Verify flag metadata includes name and type.""" - for cmd in context.commands_with_flags: - for flag in cmd["flags"]: - assert flag.get("name"), f"Flag missing name in command {cmd['name']}" - assert flag.get("flag_type"), f"Flag missing type in command {cmd['name']}" - - -@then("flag descriptions should be captured") -def step_flag_descriptions(context): - """Verify flag descriptions are captured.""" - flags_with_descriptions = 0 - for cmd in context.commands_with_flags: - for flag in cmd["flags"]: - if flag.get("description"): - flags_with_descriptions += 1 - - # We expect at least some flags to have descriptions - assert flags_with_descriptions > 0, "No flag descriptions found" diff --git a/features/steps/env_variables_steps.py b/features/steps/env_variables_steps.py deleted file mode 100644 index d5508deec..000000000 --- a/features/steps/env_variables_steps.py +++ /dev/null @@ -1,293 +0,0 @@ -"""Step definitions for environment variable extraction feature.""" - -from __future__ import annotations - -import json -from pathlib import Path -from typing import Any - -import yaml -from behave import given, then, when - -from cleveragents.discovery.env_variables import EnvironmentVariableExtractor - - -@given("a Plandex directory with environment variable documentation") -def step_given_plandex_with_env_docs(context: Any) -> None: - """Set up Plandex directory with environment documentation.""" - # Use the Plandex directory from environment.py - context.plandex_root = getattr(context, "plandex_root", Path("/app/plandex")) - context.extractor = EnvironmentVariableExtractor(context.plandex_root) - - -@when("I extract environment variables from documentation") -def step_extract_from_docs(context: Any) -> None: - """Extract environment variables from documentation.""" - context.extractor.extract_from_documentation() - context.doc_variables = context.extractor.variables.copy() - - -@then("the extractor should find documented variables") -def step_should_find_documented_vars(context: Any) -> None: - """Verify documented variables were found.""" - assert len(context.doc_variables) > 0, "Should find documented variables" - # Check for some known variables - var_names = list(context.doc_variables.keys()) - assert any("PLANDEX" in name for name in var_names), "Should find PLANDEX variables" - assert any("OPENAI" in name for name in var_names), "Should find OpenAI variables" - - -@then("each variable should have a description") -def step_each_var_has_description(context: Any) -> None: - """Verify each variable has a description.""" - for var_name, var_info in context.doc_variables.items(): - if "documentation" in var_info.get("sources", []): - assert "description" in var_info, f"{var_name} should have description" - # Most documented variables should have descriptions - if var_info["description"]: - assert len(var_info["description"]) > 0 - - -@then("each variable should have a proposed CleverAgents name") -def step_each_var_has_proposed_name(context: Any) -> None: - """Verify each variable has a proposed name.""" - for var_name, var_info in context.doc_variables.items(): - assert "proposed_cleveragents_name" in var_info, ( - f"{var_name} should have proposed name" - ) - assert var_info["proposed_cleveragents_name"], ( - f"{var_name} proposed name should not be empty" - ) - - # Check naming conventions - if var_name.startswith("PLANDEX_"): - assert var_info["proposed_cleveragents_name"].startswith("CLEVERAGENTS_"), ( - f"{var_name} should map to CLEVERAGENTS_ prefix" - ) - - -@given("a Plandex directory with Go source files") -def step_given_plandex_with_go_source(context: Any) -> None: - """Set up Plandex directory with Go source.""" - context.plandex_root = Path("plandex") - context.extractor = EnvironmentVariableExtractor(context.plandex_root) - - -@when("I extract environment variables from Go code") -def step_extract_from_go_code(context: Any) -> None: - """Extract environment variables from Go source.""" - context.extractor.extract_from_go_source() - context.code_variables = context.extractor.variables.copy() - - -@then("the extractor should find code-referenced variables") -def step_should_find_code_vars(context: Any) -> None: - """Verify code-referenced variables were found.""" - assert len(context.code_variables) > 0, "Should find code-referenced variables" - - # Check that some have code in sources - code_sourced = [ - v for v in context.code_variables.values() if "code" in v.get("sources", []) - ] - assert len(code_sourced) > 0, "Should have variables sourced from code" - - -@then("usage locations should be tracked") -def step_usage_locations_tracked(context: Any) -> None: - """Verify usage locations are tracked.""" - vars_with_locations = [ - v for v in context.code_variables.values() if v.get("usage_locations") - ] - assert len(vars_with_locations) > 0, "Should track usage locations" - - # Check format of locations - for var_info in vars_with_locations: - for location in var_info["usage_locations"]: - assert ":" in location, f"Location should have file:line format: {location}" - - -@then("variables should be categorized by source location") -def step_vars_categorized(context: Any) -> None: - """Verify variables are categorized.""" - categories = set() - for var_info in context.code_variables.values(): - if "category" in var_info: - categories.add(var_info["category"]) - - assert len(categories) > 0, "Should have categories" - # Should have some expected categories - expected = {"CLI", "Server", "General", "LLM Providers"} - assert len(categories.intersection(expected)) > 0, ( - f"Should have expected categories, found: {categories}" - ) - - -@given("an extracted set of environment variables") -def step_given_extracted_vars(context: Any) -> None: - """Set up extracted variables.""" - context.plandex_root = Path("plandex") - context.extractor = EnvironmentVariableExtractor(context.plandex_root) - context.results = context.extractor.extract_all() - - -@when("I generate the mapping table") -def step_generate_mapping(context: Any) -> None: - """Generate mapping table.""" - context.mapping = context.extractor.generate_mapping_table() - - -@then("PLANDEX variables should map to CLEVERAGENTS equivalents") -def step_plandex_maps_to_cleveragents(context: Any) -> None: - """Verify PLANDEX variables map correctly.""" - plandex_vars = [k for k in context.mapping if k.startswith("PLANDEX_")] - for old_name in plandex_vars: - new_name = context.mapping[old_name] - assert new_name.startswith("CLEVERAGENTS_"), ( - f"{old_name} should map to CLEVERAGENTS_ prefix, got {new_name}" - ) - - -@then("provider-specific variables should remain unchanged") -def step_provider_vars_unchanged(context: Any) -> None: - """Verify provider variables remain unchanged.""" - provider_prefixes = ["OPENAI_", "ANTHROPIC_", "GEMINI_", "AZURE_", "AWS_"] - - for var_name in context.results["variables"]: - for prefix in provider_prefixes: - if var_name.startswith(prefix): - # Provider vars might not be in mapping if unchanged - if var_name in context.mapping: - assert context.mapping[var_name] == var_name, ( - f"Provider variable {var_name} should remain unchanged" - ) - - -@then("generic variables should get CLEVERAGENTS prefix") -def step_generic_vars_get_prefix(context: Any) -> None: - """Verify generic variables get CLEVERAGENTS prefix.""" - generic_vars = ["PORT", "DATABASE_URL", "GOENV"] - - for var_name in generic_vars: - if var_name in context.results["variables"]: - proposed = context.results["variables"][var_name][ - "proposed_cleveragents_name" - ] - if not var_name.startswith("CLEVERAGENTS_"): - assert proposed.startswith("CLEVERAGENTS_"), ( - f"Generic variable {var_name} should get CLEVERAGENTS_ prefix" - ) - - -@when("I identify conflicts") -def step_identify_conflicts(context: Any) -> None: - """Identify conflicts.""" - context.conflicts = context.extractor.identify_conflicts() - - -@then("PLANDEX_ prefixed variables should be flagged for migration") -def step_plandex_flagged(context: Any) -> None: - """Verify PLANDEX variables are flagged.""" - migration_conflicts = [ - c for c in context.conflicts if c.get("type") == "migration_required" - ] - - if any(k.startswith("PLANDEX_") for k in context.results["variables"]): - assert len(migration_conflicts) > 0, ( - "Should flag PLANDEX variables for migration" - ) - - -@then("development-only variables should be identified") -def step_dev_vars_identified(context: Any) -> None: - """Verify development variables are identified.""" - dev_conflicts = [ - c for c in context.conflicts if c.get("type") == "development_only" - ] - - # If there are PLANDEX_DEV variables, they should be flagged - dev_vars = [k for k in context.results["variables"] if "PLANDEX_DEV" in k] - if dev_vars: - assert len(dev_conflicts) > 0, "Should identify development-only variables" - - -@then("migration guidance should be provided") -def step_migration_guidance(context: Any) -> None: - """Verify migration guidance is provided.""" - for conflict in context.conflicts: - assert "description" in conflict, "Conflict should have description" - assert "old_name" in conflict, "Conflict should have old name" - assert "new_name" in conflict, "Conflict should have new name" - assert "type" in conflict, "Conflict should have type" - - -@when("I save the results") -def step_save_results(context: Any) -> None: - """Save extraction results.""" - import tempfile - - context.temp_dir = tempfile.mkdtemp() - context.extractor.save_results(context.temp_dir) - context.output_dir = Path(context.temp_dir) - - -@then("a JSON file should be created") -def step_json_created(context: Any) -> None: - """Verify JSON file creation.""" - json_file = context.output_dir / "env_variables.json" - assert json_file.exists(), "JSON file should be created" - - # Verify it's valid JSON - with json_file.open() as f: - data = json.load(f) - assert "variables" in data - assert "conflicts" in data - assert "mapping" in data - assert "statistics" in data - - -@then("a YAML file should be created") -def step_yaml_created(context: Any) -> None: - """Verify YAML file creation.""" - yaml_file = context.output_dir / "env_variables.yaml" - assert yaml_file.exists(), "YAML file should be created" - - # Verify it's valid YAML - with yaml_file.open() as f: - data = yaml.safe_load(f) - assert "variables" in data - assert "conflicts" in data - assert "mapping" in data - assert "statistics" in data - - -@then("a mapping text file should be created") -def step_mapping_file_created(context: Any) -> None: - """Verify mapping text file creation.""" - mapping_file = context.output_dir / "env_mapping.txt" - assert mapping_file.exists(), "Mapping file should be created" - - # Verify content format - with mapping_file.open() as f: - content = f.read() - assert "Environment Variable Mapping" in content - assert "->" in content # Should have mapping arrows - - -@then("a migration guide should be generated") -def step_migration_guide_created(context: Any) -> None: - """Verify migration guide creation.""" - guide_file = context.output_dir / "env_migration_guide.md" - assert guide_file.exists(), "Migration guide should be created" - - # Verify content - with guide_file.open() as f: - content = f.read() - assert "# Environment Variable Migration Guide" in content - assert "## Overview" in content - assert "## Variable Mappings" in content - assert "| Old Name | New Name |" in content # Table header - - # Clean up temp directory - import shutil - - shutil.rmtree(context.temp_dir) diff --git a/features/steps/implicit_behaviors_steps.py b/features/steps/implicit_behaviors_steps.py deleted file mode 100644 index 0b3e60749..000000000 --- a/features/steps/implicit_behaviors_steps.py +++ /dev/null @@ -1,333 +0,0 @@ -"""Step definitions for implicit behaviors extraction.""" - -import json -import os -import shutil -from pathlib import Path - -import yaml -from behave import given, then, when - -from cleveragents.discovery.implicit_behaviors import ImplicitBehaviorExtractor - - -@given("a Plandex repository with Go source code") -def step_given_plandex_repository(context): - """Ensure we have a Plandex repository available.""" - # This is handled by the environment.py setup - pass - - -@given("an implicit behavior extractor initialized with the repository") -def step_init_behavior_extractor(context): - """Initialize the implicit behavior extractor.""" - plandex_root = context.plandex_root or "plandex" - context.extractor = ImplicitBehaviorExtractor(plandex_root) - - -@when("I extract implicit behaviors from the codebase") -def step_extract_behaviors(context): - """Extract implicit behaviors.""" - context.results = context.extractor.extract_all() - - -@when('I save the results to "{output_dir}"') -def step_save_behavior_results(context, output_dir): - """Save extraction results to specified directory.""" - context.output_dir = output_dir - # Clean up test directory if it exists - if os.path.exists(output_dir): - shutil.rmtree(output_dir) - context.extractor.save_results(output_dir) - - -@then("the results should contain auto-context behaviors") -def step_check_auto_context(context): - """Check for auto-context behaviors.""" - categories = context.results.get("by_category", {}) - assert "auto-context" in categories, "No auto-context behaviors found" - assert len(categories["auto-context"]) > 0, "Auto-context category is empty" - - -@then("each auto-context behavior should have triggers listed") -def step_check_triggers(context): - """Check that auto-context behaviors have triggers.""" - behaviors = context.results.get("by_category", {}).get("auto-context", []) - for behavior in behaviors: - assert behavior.get("triggers"), f"Behavior {behavior['name']} has no triggers" - assert len(behavior["triggers"]) > 0, ( - f"Behavior {behavior['name']} has empty triggers" - ) - - -@then("each behavior should have Python migration considerations") -def step_check_python_notes(context): - """Check that behaviors have Python migration notes.""" - for behavior in context.results.get("behaviors", []): - assert behavior.get("python_considerations"), ( - f"Behavior {behavior['name']} has no Python notes" - ) - assert len(behavior["python_considerations"]) > 0 - - -@then("the results should contain locking behaviors") -def step_check_locking(context): - """Check for locking behaviors.""" - categories = context.results.get("by_category", {}) - assert "locking" in categories, "No locking behaviors found" - - -@then("locking behaviors should reference mutex or file lock patterns") -def step_check_locking_patterns(context): - """Check locking behavior patterns.""" - behaviors = context.results.get("by_category", {}).get("locking", []) - for behavior in behaviors: - desc = behavior.get("description", "").lower() - name = behavior.get("name", "").lower() - assert any( - term in desc or term in name for term in ["mutex", "lock", "sync"] - ), f"Locking behavior doesn't mention expected patterns: {behavior['name']}" - - -@then("Python alternatives should mention threading or asyncio locks") -def step_check_python_locking(context): - """Check Python locking alternatives.""" - behaviors = context.results.get("by_category", {}).get("locking", []) - for behavior in behaviors: - notes = " ".join(behavior.get("python_considerations", [])).lower() - assert any(term in notes for term in ["threading", "asyncio", "lock"]), ( - f"Locking behavior lacks Python alternatives: {behavior['name']}" - ) - - -@then("the results should contain retry behaviors") -def step_check_retry(context): - """Check for retry behaviors.""" - categories = context.results.get("by_category", {}) - assert "retry" in categories, "No retry behaviors found" - - -@then("retry behaviors should mention exponential backoff") -def step_check_backoff(context): - """Check for backoff patterns.""" - behaviors = context.results.get("by_category", {}).get("retry", []) - if behaviors: # Only check if we found retry behaviors - all_text = "" - for behavior in behaviors: - all_text += behavior.get("description", "").lower() - all_text += behavior.get("timing", "").lower() - all_text += behavior.get("name", "").lower() - assert "backoff" in all_text or "exponential" in all_text, ( - "Retry behaviors don't mention backoff patterns" - ) - - -@then("Python considerations should suggest tenacity or backoff libraries") -def step_check_python_retry(context): - """Check Python retry library suggestions.""" - behaviors = context.results.get("by_category", {}).get("retry", []) - if behaviors: - for behavior in behaviors: - notes = " ".join(behavior.get("python_considerations", [])).lower() - assert any(term in notes for term in ["tenacity", "backoff", "retry"]), ( - f"Retry behavior lacks Python library suggestions: {behavior['name']}" - ) - - -@then("the results should contain validation behaviors") -def step_check_validation(context): - """Check for validation behaviors.""" - categories = context.results.get("by_category", {}) - assert "validation" in categories, "No validation behaviors found" - - -@then("validation behaviors should reference input checks") -def step_check_validation_patterns(context): - """Check validation patterns.""" - behaviors = context.results.get("by_category", {}).get("validation", []) - for behavior in behaviors: - desc = behavior.get("description", "").lower() - assert any( - term in desc for term in ["validation", "sanitiz", "check", "input"] - ), f"Validation behavior doesn't mention expected patterns: {behavior['name']}" - - -@then("Python notes should mention pydantic or marshmallow") -def step_check_python_validation(context): - """Check Python validation library suggestions.""" - behaviors = context.results.get("by_category", {}).get("validation", []) - for behavior in behaviors: - notes = " ".join(behavior.get("python_considerations", [])).lower() - assert any(term in notes for term in ["pydantic", "marshmallow", "validat"]), ( - f"Validation behavior lacks Python library suggestions: {behavior['name']}" - ) - - -@then("the results should contain concurrency behaviors") -def step_check_concurrency(context): - """Check for concurrency behaviors.""" - categories = context.results.get("by_category", {}) - assert "concurrency" in categories, "No concurrency behaviors found" - - -@then("concurrency behaviors should reference goroutines or channels") -def step_check_concurrency_patterns(context): - """Check concurrency patterns.""" - behaviors = context.results.get("by_category", {}).get("concurrency", []) - for behavior in behaviors: - all_text = (behavior.get("name", "") + behavior.get("description", "")).lower() - assert any( - term in all_text - for term in ["goroutine", "channel", "concurrent", "waitgroup"] - ), f"Concurrency behavior doesn't mention expected patterns: {behavior['name']}" - - -@then("Python alternatives should mention asyncio or threading") -def step_check_python_concurrency(context): - """Check Python concurrency alternatives.""" - behaviors = context.results.get("by_category", {}).get("concurrency", []) - for behavior in behaviors: - notes = " ".join(behavior.get("python_considerations", [])).lower() - assert any(term in notes for term in ["asyncio", "threading", "queue"]), ( - f"Concurrency behavior lacks Python alternatives: {behavior['name']}" - ) - - -@then("the results should contain streaming behaviors") -def step_check_streaming(context): - """Check for streaming behaviors.""" - categories = context.results.get("by_category", {}) - assert "streaming" in categories, "No streaming behaviors found" - - -@then("streaming behaviors should reference WebSocket or SSE") -def step_check_streaming_patterns(context): - """Check streaming patterns.""" - behaviors = context.results.get("by_category", {}).get("streaming", []) - for behavior in behaviors: - all_text = (behavior.get("name", "") + behavior.get("description", "")).lower() - assert any( - term in all_text for term in ["websocket", "sse", "stream", "server-sent"] - ), f"Streaming behavior doesn't mention expected patterns: {behavior['name']}" - - -@then("Python considerations should mention aiohttp") -def step_check_python_streaming(context): - """Check Python streaming library suggestions.""" - behaviors = context.results.get("by_category", {}).get("streaming", []) - for behavior in behaviors: - notes = " ".join(behavior.get("python_considerations", [])).lower() - assert any(term in notes for term in ["aiohttp", "websocket", "async"]), ( - f"Streaming behavior lacks Python library suggestions: {behavior['name']}" - ) - - -@then("the results should include sequence diagrams") -def step_check_diagrams(context): - """Check for sequence diagrams.""" - assert "sequence_diagrams" in context.results, "No sequence diagrams found" - assert len(context.results["sequence_diagrams"]) > 0, "Sequence diagrams are empty" - - -@then("there should be a diagram for auto-context loading") -def step_check_context_diagram(context): - """Check for auto-context loading diagram.""" - diagrams = context.results.get("sequence_diagrams", {}) - assert "auto_context_loading" in diagrams, "No auto-context loading diagram" - - -@then("there should be a diagram for retry with backoff") -def step_check_retry_diagram(context): - """Check for retry diagram.""" - diagrams = context.results.get("sequence_diagrams", {}) - assert "retry_with_backoff" in diagrams, "No retry with backoff diagram" - - -@then("there should be a diagram for git locking") -def step_check_locking_diagram(context): - """Check for git locking diagram.""" - diagrams = context.results.get("sequence_diagrams", {}) - assert "git_locking" in diagrams, "No git locking diagram" - - -@then("a JSON file should be created with the behaviors") -def step_check_json_file(context): - """Check that JSON file was created.""" - json_file = Path(context.output_dir) / "implicit_behaviors.json" - assert json_file.exists(), f"JSON file not found: {json_file}" - - with open(json_file) as f: - data = json.load(f) - assert "behaviors" in data, "JSON missing behaviors" - assert "by_category" in data, "JSON missing categories" - - -@then("a YAML file should be created with the behaviors") -def step_check_yaml_file(context): - """Check that YAML file was created.""" - yaml_file = Path(context.output_dir) / "implicit_behaviors.yaml" - assert yaml_file.exists(), f"YAML file not found: {yaml_file}" - - with open(yaml_file) as f: - data = yaml.safe_load(f) - assert "behaviors" in data, "YAML missing behaviors" - assert "by_category" in data, "YAML missing categories" - - -@then("a Markdown documentation file should be created") -def step_check_markdown_file(context): - """Check that Markdown file was created.""" - md_file = Path(context.output_dir) / "implicit_behaviors.md" - assert md_file.exists(), f"Markdown file not found: {md_file}" - - with open(md_file) as f: - content = f.read() - assert "# Implicit Behaviors" in content, "Missing main heading" - assert "## Summary" in content, "Missing summary section" - assert "## Behaviors by Category" in content, "Missing categories section" - - -@then("the documentation should include all behavior categories") -def step_check_doc_categories(context): - """Check that documentation includes all categories.""" - md_file = Path(context.output_dir) / "implicit_behaviors.md" - with open(md_file) as f: - content = f.read() - - categories = context.results.get("by_category", {}).keys() - for category in categories: - assert f"### {category.title()}" in content, f"Missing category: {category}" - - -@then("the statistics should include Python migration considerations") -def step_check_migration_stats(context): - """Check for migration considerations in statistics.""" - stats = context.results.get("statistics", {}) - assert "python_migration_considerations" in stats, ( - "Missing migration considerations" - ) - assert len(stats["python_migration_considerations"]) > 0, ( - "Empty migration considerations" - ) - - -@then("the migration notes should be unique") -def step_check_unique_notes(context): - """Check that migration notes are deduplicated.""" - notes = context.results["statistics"]["python_migration_considerations"] - assert len(notes) == len(set(notes)), "Duplicate migration notes found" - - -@then("the notes should cover asyncio, threading, and validation libraries") -def step_check_note_coverage(context): - """Check that migration notes cover key topics.""" - notes = " ".join( - context.results["statistics"]["python_migration_considerations"] - ).lower() - assert "asyncio" in notes, "Missing asyncio in migration notes" - assert "threading" in notes or "thread" in notes, ( - "Missing threading in migration notes" - ) - assert any(term in notes for term in ["pydantic", "marshmallow", "validat"]), ( - "Missing validation libraries in migration notes" - ) diff --git a/features/steps/server_endpoints_steps.py b/features/steps/server_endpoints_steps.py deleted file mode 100644 index 4fbaff483..000000000 --- a/features/steps/server_endpoints_steps.py +++ /dev/null @@ -1,248 +0,0 @@ -"""Step definitions for server endpoint extraction features.""" - -import json -from pathlib import Path - -import yaml -from behave import given, then, when - - -@given("the server endpoint extractor is initialized") -def step_initialize_server_extractor(context): - """Initialize the server endpoint extractor.""" - from cleveragents.discovery.server_endpoints import ServerEndpointExtractor - - context.server_extractor = ServerEndpointExtractor() - - -@when("I run the server endpoint extraction") -def step_run_server_extraction(context): - """Run the server endpoint extraction.""" - context.server_inventory = context.server_extractor.extract_endpoints() - context.extraction_succeeded = context.server_inventory is not None - - -@then("at least {count:d} endpoints should be extracted") -def step_check_endpoint_count(context, count): - """Check minimum number of endpoints extracted.""" - actual = context.server_inventory["statistics"]["total_endpoints"] - assert actual >= count, f"Expected at least {count} endpoints, got {actual}" - - -@then("the inventory should include endpoint metadata") -def step_check_endpoint_metadata(context): - """Check that endpoint metadata is included.""" - assert "metadata" in context.server_inventory - assert "statistics" in context.server_inventory - assert "endpoints_by_category" in context.server_inventory - assert "all_endpoints" in context.server_inventory - - -@then("the server inventory can be saved") -def step_server_inventory_can_be_saved(context): - """Verify server inventory can be saved.""" - # For server endpoints, we just verify that we could save if we wanted to - # The actual save is done separately - assert hasattr(context, "server_extractor") - assert hasattr(context, "server_inventory") - - -@given("the server endpoints have been extracted") -def step_extract_server_endpoints(context): - """Extract server endpoints if not already done.""" - if not hasattr(context, "server_inventory"): - from cleveragents.discovery.server_endpoints import ServerEndpointExtractor - - context.server_extractor = ServerEndpointExtractor() - context.server_inventory = context.server_extractor.extract_endpoints() - # Always ensure endpoints attribute is populated - context.endpoints = context.server_inventory["all_endpoints"] - - -@when("I check the endpoint structure") -def step_check_endpoint_structure(context): - """Check endpoint structure.""" - context.endpoints = context.server_inventory["all_endpoints"] - - -@then("each endpoint should have a path") -def step_check_endpoint_paths(context): - """Check all endpoints have paths.""" - for endpoint in context.endpoints: - assert "path" in endpoint, f"Endpoint missing path: {endpoint}" - assert endpoint["path"], f"Endpoint has empty path: {endpoint}" - - -@then("each endpoint should have a method") -def step_check_endpoint_methods(context): - """Check all endpoints have methods.""" - for endpoint in context.endpoints: - assert "method" in endpoint, f"Endpoint missing method: {endpoint}" - assert endpoint["method"], f"Endpoint has empty method: {endpoint}" - - -@then("each endpoint should have a handler") -def step_check_endpoint_handlers(context): - """Check all endpoints have handlers.""" - for endpoint in context.endpoints: - assert "handler" in endpoint, f"Endpoint missing handler: {endpoint}" - assert endpoint["handler"], f"Endpoint has empty handler: {endpoint}" - - -@then("streaming endpoints should be identified") -def step_check_streaming_endpoints(context): - """Check that streaming endpoints are identified.""" - streaming_count = context.server_inventory["statistics"]["streaming_endpoints"] - assert streaming_count > 0, "No streaming endpoints identified" - - # Check that some endpoints have is_streaming flag - streaming = [e for e in context.endpoints if e.get("is_streaming")] - assert len(streaming) == streaming_count - - -@when("I save the server endpoint inventory") -def step_save_server_inventory(context): - """Save the server endpoint inventory.""" - if not hasattr(context, "server_extractor"): - from cleveragents.discovery.server_endpoints import ServerEndpointExtractor - - context.server_extractor = ServerEndpointExtractor() - context.server_inventory = context.server_extractor.extract_endpoints() - - context.yaml_path, context.json_path = context.server_extractor.save_inventory() - - -@then('an OpenAPI spec should be created at "{path}"') -def step_check_openapi_spec(context, path): - """Check OpenAPI spec file creation.""" - spec_path = Path(path) - assert spec_path.exists(), f"OpenAPI spec not found at {path}" - - # Validate it's a valid YAML file with OpenAPI structure - with open(spec_path) as f: - spec = yaml.safe_load(f) - - assert "openapi" in spec, "Invalid OpenAPI spec - missing openapi version" - assert "info" in spec, "Invalid OpenAPI spec - missing info section" - assert "paths" in spec, "Invalid OpenAPI spec - missing paths section" - - -@then("all files should contain consistent data") -def step_check_file_consistency(context): - """Check that all output files contain consistent data.""" - with open(context.yaml_path) as f: - yaml_data = yaml.safe_load(f) - - with open(context.json_path) as f: - json_data = json.load(f) - - # Check that YAML and JSON have same endpoint count - yaml_count = yaml_data["statistics"]["total_endpoints"] - json_count = json_data["statistics"]["total_endpoints"] - assert yaml_count == json_count, ( - f"Inconsistent endpoint count: YAML={yaml_count}, JSON={json_count}" - ) - - -@when("I check endpoint categorization") -def step_check_categorization(context): - """Check endpoint categorization.""" - context.categories = context.server_inventory["endpoints_by_category"] - - -@then("endpoints should be grouped by category") -def step_check_category_groups(context): - """Check that endpoints are grouped by category.""" - assert len(context.categories) > 0, "No categories found" - - # Check each category has endpoints - for category, endpoints in context.categories.items(): - assert len(endpoints) > 0, f"Category '{category}' has no endpoints" - - -@then("categories should include {category}") -def step_check_specific_category(context, category): - """Check for specific category.""" - assert category in context.categories, ( - f"Category '{category}' not found. Available: {list(context.categories.keys())}" - ) - - -@when("I check for path parameters") -def step_check_path_params(context): - """Check for path parameters.""" - context.params_endpoints = [ - e - for e in context.endpoints - if e.get("path_params") and len(e["path_params"]) > 0 - ] - - -@then("endpoints with path parameters should be identified") -def step_check_param_endpoints(context): - """Check that endpoints with path parameters are identified.""" - assert len(context.params_endpoints) > 0, "No endpoints with path parameters found" - - -@then("path parameter names should be extracted") -def step_check_param_names(context): - """Check that parameter names are extracted.""" - for endpoint in context.params_endpoints: - assert "path_params" in endpoint - assert isinstance(endpoint["path_params"], list) - assert all(isinstance(p, str) for p in endpoint["path_params"]) - - -@then("parameters like {param} and {param2} should be found") -def step_check_specific_params(context, param, param2): - """Check for specific parameters.""" - all_params = set() - for endpoint in context.params_endpoints: - all_params.update(endpoint["path_params"]) - - assert param in all_params, ( - f"Parameter '{param}' not found. Available: {all_params}" - ) - assert param2 in all_params, ( - f"Parameter '{param2}' not found. Available: {all_params}" - ) - - -@when("I check authentication requirements") -def step_check_auth_requirements(context): - """Check authentication requirements.""" - context.public_endpoints = [ - e for e in context.endpoints if not e.get("requires_auth", True) - ] - context.protected_endpoints = [ - e for e in context.endpoints if e.get("requires_auth", True) - ] - - -@then("public endpoints should be identified") -def step_check_public_endpoints(context): - """Check that public endpoints are identified.""" - assert len(context.public_endpoints) > 0, "No public endpoints found" - - -@then("protected endpoints should be identified") -def step_check_protected_endpoints(context): - """Check that protected endpoints are identified.""" - assert len(context.protected_endpoints) > 0, "No protected endpoints found" - - -@then("{endpoint} and {endpoint2} endpoints should be public") -def step_check_specific_public(context, endpoint, endpoint2): - """Check specific endpoints are public.""" - public_paths = [e["path"] for e in context.public_endpoints] - - # Check if endpoints contain the keywords - health_found = any(endpoint.lower() in path.lower() for path in public_paths) - version_found = any(endpoint2.lower() in path.lower() for path in public_paths) - - assert health_found, ( - f"'{endpoint}' endpoint not found in public endpoints: {public_paths}" - ) - assert version_found, ( - f"'{endpoint2}' endpoint not found in public endpoints: {public_paths}" - ) diff --git a/features/steps/shell_asset_steps.py b/features/steps/shell_asset_steps.py deleted file mode 100644 index c7dc110aa..000000000 --- a/features/steps/shell_asset_steps.py +++ /dev/null @@ -1,245 +0,0 @@ -"""Step definitions for shell asset extraction features.""" - -import json -from pathlib import Path - -from behave import given, then, when - -from cleveragents.discovery.shell_assets import ShellAssetExtractor - - -@given("the Plandex Go repository exists") -def step_given_plandex_exists(context): - """Set up context for Plandex repository existence.""" - # This is a precondition that should be satisfied for tests to run - # The actual Plandex repository should exist at ../plandex relative to the project root - pass - - -@given("the ShellAssetExtractor is initialized") -def step_init_shell_extractor(context): - """Initialize the shell asset extractor.""" - context.shell_extractor = ShellAssetExtractor() - - -@when("I run the shell asset extraction") -def step_run_shell_extraction(context): - """Run the shell asset extraction.""" - context.shell_catalog = context.shell_extractor.extract_all() - - -@when("I extract shell assets") -def step_extract_shell_assets(context): - """Extract shell assets.""" - context.shell_catalog = context.shell_extractor.extract_all() - - -@when("I save the catalog") -def step_save_catalog(context): - """Save the catalog files.""" - context.shell_extractor.save_catalog("build/test_output/shell") - context.output_dir = Path("build/test_output/shell") - - -@when("I save the catalog with wrappers") -def step_save_catalog_with_wrappers(context): - """Save the catalog with Python wrappers.""" - context.shell_extractor.save_catalog("build/test_output/shell") - context.output_dir = Path("build/test_output/shell") - - -@then("shell scripts should be discovered") -def step_verify_scripts_discovered(context): - """Verify shell scripts were discovered.""" - assert context.shell_catalog is not None - assert "scripts" in context.shell_catalog - assert len(context.shell_catalog["scripts"]) > 0 - - -@then("each script should have metadata extracted") -def step_verify_metadata_extracted(context): - """Verify metadata was extracted for each script.""" - for script in context.shell_catalog["scripts"]: - assert "path" in script - assert "name" in script - assert "commands_used" in script - assert "environment_vars" in script - - -@then("the start_local.sh script should be found") -def step_verify_start_local_found(context): - """Verify start_local.sh is found.""" - scripts = context.shell_catalog["scripts"] - start_local = [s for s in scripts if s["name"] == "start_local.sh"] - assert len(start_local) > 0, "start_local.sh not found" - context.start_local_script = start_local[0] - - -@then("it should be marked as requiring Docker") -def step_verify_docker_required(context): - """Verify script is marked as requiring Docker.""" - assert context.start_local_script["requires_docker"] is True - - -@then("it should be marked as requiring Git") -def step_verify_git_required(context): - """Verify script is marked as requiring Git.""" - assert context.start_local_script["requires_git"] is True - - -@then("it should be suggested for Python replacement") -def step_verify_python_replacement(context): - """Verify script is suggested for Python replacement.""" - assert context.start_local_script["python_replacement_suggested"] is True - - -@then("environment variables should be identified") -def step_verify_env_vars_identified(context): - """Verify environment variables are identified.""" - assert "environment_map" in context.shell_catalog - assert len(context.shell_catalog["environment_map"]) > 0 - - -@then("each variable should be mapped to its scripts") -def step_verify_var_script_mapping(context): - """Verify each variable is mapped to scripts.""" - env_map = context.shell_catalog["environment_map"] - for _var, scripts in env_map.items(): - assert isinstance(scripts, list) - assert len(scripts) > 0 - - -@then("scripts requiring Docker should be identified") -def step_verify_docker_scripts(context): - """Verify scripts requiring Docker are identified.""" - docker_scripts = [ - s for s in context.shell_catalog["scripts"] if s["requires_docker"] - ] - assert len(docker_scripts) > 0 - - -@then("scripts requiring Git should be identified") -def step_verify_git_scripts(context): - """Verify scripts requiring Git are identified.""" - git_scripts = [s for s in context.shell_catalog["scripts"] if s["requires_git"]] - assert len(git_scripts) > 0 - - -@then("command dependencies should be captured") -def step_verify_command_dependencies(context): - """Verify command dependencies are captured.""" - for script in context.shell_catalog["scripts"]: - assert isinstance(script["commands_used"], list) - - -@then("Python wrapper files should be created") -def step_verify_wrapper_files(context): - """Verify Python wrapper files are created.""" - wrappers_dir = context.output_dir / "shell_wrappers" - if wrappers_dir.exists(): - wrapper_files = list(wrappers_dir.glob("*.py")) - assert len(wrapper_files) > 0 - - -@then("wrappers should include documentation") -def step_verify_wrapper_docs(context): - """Verify wrappers include documentation.""" - wrappers_dir = context.output_dir / "shell_wrappers" - if wrappers_dir.exists(): - for wrapper_file in wrappers_dir.glob("*.py"): - content = wrapper_file.read_text() - assert '"""' in content or "'''" in content - - -@then("wrappers should preserve environment variable handling") -def step_verify_wrapper_env_handling(context): - """Verify wrappers preserve environment variable handling.""" - wrappers_dir = context.output_dir / "shell_wrappers" - if wrappers_dir.exists(): - for wrapper_file in wrappers_dir.glob("*.py"): - content = wrapper_file.read_text() - assert "env" in content - assert "os.environ" in content - - -@then("a YAML catalog file should be created") -def step_verify_yaml_catalog(context): - """Verify YAML catalog file is created.""" - yaml_file = context.output_dir / "shell_assets.yaml" - assert yaml_file.exists() - - -@then("a JSON catalog file should be created") -def step_verify_json_catalog(context): - """Verify JSON catalog file is created.""" - json_file = context.output_dir / "shell_assets.json" - assert json_file.exists() - - -@then("both catalog files should contain the same data") -def step_verify_catalog_consistency(context): - """Verify YAML and JSON files contain the same data.""" - import yaml - - yaml_file = context.output_dir / "shell_assets.yaml" - json_file = context.output_dir / "shell_assets.json" - - with open(yaml_file) as f: - yaml_data = yaml.safe_load(f) - - with open(json_file) as f: - json_data = json.load(f) - - assert yaml_data == json_data - - -@then("idempotent scripts should be marked") -def step_verify_idempotent_marked(context): - """Verify idempotent scripts are marked.""" - idempotent_scripts = [ - s for s in context.shell_catalog["scripts"] if s["idempotent"] - ] - assert len(idempotent_scripts) > 0 - - -@then("scripts with mkdir -p should be idempotent") -def step_verify_mkdir_idempotent(context): - """Verify scripts with mkdir -p are marked idempotent.""" - # This is handled by the analyzer logic - pass - - -@then("scripts with test checks should be idempotent") -def step_verify_test_idempotent(context): - """Verify scripts with test checks are marked idempotent.""" - # This is handled by the analyzer logic - pass - - -@then("test scripts should be identified") -def step_verify_test_scripts(context): - """Verify test scripts are identified.""" - test_scripts = [ - s for s in context.shell_catalog["scripts"] if "test" in s["name"].lower() - ] - assert len(test_scripts) > 0 - - -@then("development scripts should be identified") -def step_verify_dev_scripts(context): - """Verify development scripts are identified.""" - [s for s in context.shell_catalog["scripts"] if "dev" in s["name"].lower()] - # May or may not have dev scripts - pass - - -@then("code generation scripts should be identified") -def step_verify_gen_scripts(context): - """Verify code generation scripts are identified.""" - [ - s - for s in context.shell_catalog["scripts"] - if "gen" in s["name"].lower() or "provider" in s["name"].lower() - ] - # May or may not have generation scripts - pass diff --git a/features/steps/workflow_parity_steps.py b/features/steps/workflow_parity_steps.py deleted file mode 100644 index 8e9cf7ef0..000000000 --- a/features/steps/workflow_parity_steps.py +++ /dev/null @@ -1,313 +0,0 @@ -"""Step definitions for workflow parity feature.""" - -import json -from pathlib import Path - -from behave import given, then, when - -from cleveragents.discovery.workflow_parity import WorkflowParityExtractor - - -@given("the workflow parity extractor is initialized") -def step_init_workflow_extractor(context): - """Initialize the workflow parity extractor.""" - plandex_dir = Path(__file__).parent.parent.parent / "plandex" - context.workflow_extractor = WorkflowParityExtractor(plandex_dir) - - -@when("I run the workflow parity extraction") -def step_run_workflow_extraction(context): - """Run the workflow extraction.""" - context.workflow_results = context.workflow_extractor.extract_all() - - -@when("I extract workflows and generate the parity matrix") -def step_extract_and_generate_matrix(context): - """Extract workflows and generate parity matrix.""" - context.workflow_results = context.workflow_extractor.extract_all() - context.parity_matrix = context.workflow_results["matrix"] - - -@when("I extract plan-related workflows") -def step_extract_plan_workflows(context): - """Extract plan lifecycle workflows.""" - context.workflow_extractor._extract_plan_workflows() - context.plan_workflows = { - k: v - for k, v in context.workflow_extractor.workflows.items() - if v.get("category") == "plan_lifecycle" - } - - -@when("I extract context workflows") -def step_extract_context_workflows(context): - """Extract context management workflows.""" - context.workflow_extractor._extract_context_workflows() - context.context_workflows = { - k: v - for k, v in context.workflow_extractor.workflows.items() - if v.get("category") == "context_management" - } - - -@when("I extract execution workflows") -def step_extract_execution_workflows(context): - """Extract execution workflows.""" - context.workflow_extractor._extract_exec_workflows() - context.exec_workflows = { - k: v - for k, v in context.workflow_extractor.workflows.items() - if v.get("category") == "execution_flows" - } - - -@when("I extract all workflows") -def step_extract_all_workflows(context): - """Extract all workflows.""" - context.workflow_results = context.workflow_extractor.extract_all() - - -@given("I have extracted workflow mappings") -def step_have_workflow_mappings(context): - """Ensure workflow mappings are extracted.""" - if not hasattr(context, "workflow_results"): - context.workflow_results = context.workflow_extractor.extract_all() - - -@when("I save the workflow parity results") -def step_save_workflow_results(context): - """Save workflow parity results.""" - output_dir = Path("build/test_output/workflows") - context.json_file, context.yaml_file = context.workflow_extractor.save_results( - output_dir - ) - - -@then("I should get workflow mappings for all categories") -def step_check_workflow_categories(context): - """Check that all categories have workflows.""" - context.workflow_results["categories"] - workflows = context.workflow_results["workflows"] - - # Check that we have workflows in multiple categories - workflow_categories = set(w.get("category") for w in workflows.values()) - assert len(workflow_categories) > 5, ( - f"Expected multiple categories, got {workflow_categories}" - ) - - -@then("each workflow should have Go components mapped") -def step_check_go_components(context): - """Check that workflows have Go components.""" - workflows = context.workflow_results["workflows"] - for workflow_id, workflow in workflows.items(): - assert "go_components" in workflow, f"Missing go_components in {workflow_id}" - assert len(workflow["go_components"]) > 0, f"No Go components in {workflow_id}" - - -@then("each workflow should have Python modules assigned") -def step_check_python_modules(context): - """Check that workflows have Python modules.""" - workflows = context.workflow_results["workflows"] - for workflow_id, workflow in workflows.items(): - assert "python_modules" in workflow, f"Missing python_modules in {workflow_id}" - assert len(workflow["python_modules"]) > 0, ( - f"No Python modules in {workflow_id}" - ) - - -@then("the statistics should include workflow counts") -def step_check_workflow_statistics(context): - """Check workflow statistics.""" - stats = context.workflow_results["statistics"] - assert "total_workflows" in stats - assert stats["total_workflows"] > 0 - assert "workflows_per_category" in stats - assert "total_go_components" in stats - assert "total_python_modules" in stats - - -@then("the matrix should map Go components to Python modules") -def step_check_go_to_python_mapping(context): - """Check Go to Python mapping in matrix.""" - assert "go_to_python" in context.parity_matrix - assert len(context.parity_matrix["go_to_python"]) > 0 - - -@then("the matrix should identify coverage gaps") -def step_check_coverage_gaps(context): - """Check that coverage gaps are identified.""" - assert "coverage_gaps" in context.parity_matrix - # Coverage gaps may be empty if all tests are defined - - -@then("the matrix should provide implementation order") -def step_check_implementation_order(context): - """Check implementation order in matrix.""" - assert "implementation_order" in context.parity_matrix - assert len(context.parity_matrix["implementation_order"]) > 0 - - -@then("the implementation order should respect dependencies") -def step_check_dependency_order(context): - """Check that implementation order respects dependencies.""" - order = context.parity_matrix["implementation_order"] - workflows = context.workflow_results["workflows"] - - # Basic check - auth workflows should come before workflows that depend on them - auth_index = -1 - for i, wf_id in enumerate(order): - if workflows.get(wf_id, {}).get("category") == "authentication": - auth_index = i - break - - # Check that workflows depending on auth come after - for i, wf_id in enumerate(order): - wf = workflows.get(wf_id, {}) - if "authentication" in wf.get("dependencies", []): - assert i > auth_index or auth_index == -1, ( - f"{wf_id} should come after auth workflows" - ) - - -@then("a JSON file should be created with workflow data") -def step_check_json_file(context): - """Check JSON file creation.""" - assert context.json_file.exists() - with open(context.json_file) as f: - data = json.load(f) - assert "workflows" in data - assert "matrix" in data - - -@then("a YAML file should be created with workflow data") -def step_check_yaml_file(context): - """Check YAML file creation.""" - assert context.yaml_file.exists() - - -@then("a Markdown documentation should be generated") -def step_check_markdown_doc(context): - """Check Markdown documentation.""" - md_file = context.json_file.parent / "workflow_parity.md" - assert md_file.exists() - content = md_file.read_text() - assert "# Workflow Parity Matrix" in content - - -@then("the documentation should include all workflows by category") -def step_check_doc_categories(context): - """Check documentation includes categories.""" - md_file = context.json_file.parent / "workflow_parity.md" - content = md_file.read_text() - for category in context.workflow_results["categories"]: - category_title = category.replace("_", " ").title() - assert category_title in content - - -@then("I should find {workflow_id} workflow") -def step_find_workflow(context, workflow_id): - """Check that a specific workflow exists.""" - # Try to find the workflow in the appropriate context attribute - if hasattr(context, "plan_workflows") and workflow_id in context.plan_workflows: - return - if ( - hasattr(context, "context_workflows") - and workflow_id in context.context_workflows - ): - return - if hasattr(context, "exec_workflows") and workflow_id in context.exec_workflows: - return - - # If not found in any specific category, check all workflows - if hasattr(context, "workflow_extractor"): - workflows = context.workflow_extractor.workflows - assert workflow_id in workflows, f"Workflow {workflow_id} not found" - else: - raise AssertionError(f"Workflow {workflow_id} not found in any category") - - -@then("each workflow should have stages defined") -def step_check_workflow_stages(context): - """Check that workflows have stages.""" - workflow_collections = [] - - # Add only the workflow collections that exist - if hasattr(context, "plan_workflows"): - workflow_collections.append(context.plan_workflows) - if hasattr(context, "context_workflows"): - workflow_collections.append(context.context_workflows) - if hasattr(context, "exec_workflows"): - workflow_collections.append(context.exec_workflows) - - for workflows in workflow_collections: - if workflows: - for wf_id, workflow in workflows.items(): - assert "stages" in workflow, f"No stages in {wf_id}" - assert len(workflow["stages"]) > 0, f"Empty stages in {wf_id}" - - -@then("each workflow should have test coverage specified") -def step_check_test_coverage(context): - """Check test coverage specification.""" - for workflows in [context.plan_workflows]: - for wf_id, workflow in workflows.items(): - assert "test_coverage" in workflow, f"No test_coverage in {wf_id}" - - -@then("the workflows should include heuristics information") -def step_check_heuristics_info(context): - """Check for heuristics information.""" - auto_context = context.context_workflows.get("context_auto") - assert auto_context is not None - assert "heuristics" in auto_context.get("notes", "").lower() or any( - "heuristics" in stage["name"].lower() - for stage in auto_context.get("stages", []) - ) - - -@then("the workflows should include retry logic details") -def step_check_retry_logic(context): - """Check for retry logic details.""" - auto_debug = context.exec_workflows.get("auto_debug") - assert auto_debug is not None - assert "retry" in auto_debug.get("notes", "").lower() or "retry" in str( - auto_debug.get("dependencies", []) - ) - - -@then("the statistics should include total workflows") -def step_check_total_workflows(context): - """Check total workflows statistic.""" - stats = context.workflow_results["statistics"] - assert stats["total_workflows"] > 0 - - -@then("the statistics should include workflows per category") -def step_check_workflows_per_category(context): - """Check workflows per category statistic.""" - stats = context.workflow_results["statistics"] - assert len(stats["workflows_per_category"]) > 0 - - -@then("the statistics should include total Go components") -def step_check_total_go_components(context): - """Check total Go components statistic.""" - stats = context.workflow_results["statistics"] - assert stats["total_go_components"] > 0 - - -@then("the statistics should include total Python modules") -def step_check_total_python_modules(context): - """Check total Python modules statistic.""" - stats = context.workflow_results["statistics"] - assert stats["total_python_modules"] > 0 - - -@then("the statistics should include test coverage metrics") -def step_check_test_coverage_metrics(context): - """Check test coverage metrics.""" - stats = context.workflow_results["statistics"] - assert "test_coverage" in stats - assert "with_behave" in stats["test_coverage"] - assert "with_robot" in stats["test_coverage"] diff --git a/features/workflow_parity.feature b/features/workflow_parity.feature deleted file mode 100644 index 01e695a32..000000000 --- a/features/workflow_parity.feature +++ /dev/null @@ -1,58 +0,0 @@ -Feature: Workflow Parity Matrix - As a developer migrating from Plandex to CleverAgents - I want to extract and map workflows between implementations - So that I can ensure complete feature parity - - Background: - Given the Plandex Go codebase is available - And the workflow parity extractor is initialized - - Scenario: Extract all workflow categories - When I run the workflow parity extraction - Then I should get workflow mappings for all categories - And each workflow should have Go components mapped - And each workflow should have Python modules assigned - And the statistics should include workflow counts - - Scenario: Generate parity matrix - When I extract workflows and generate the parity matrix - Then the matrix should map Go components to Python modules - And the matrix should identify coverage gaps - And the matrix should provide implementation order - And the implementation order should respect dependencies - - Scenario: Save workflow parity results - Given I have extracted workflow mappings - When I save the workflow parity results - Then a JSON file should be created with workflow data - And a YAML file should be created with workflow data - And a Markdown documentation should be generated - And the documentation should include all workflows by category - - Scenario: Extract plan lifecycle workflows - When I extract plan-related workflows - Then I should find plan_create workflow - And I should find plan_build workflow - And I should find plan_apply workflow - And each workflow should have stages defined - And each workflow should have test coverage specified - - Scenario: Extract context management workflows - When I extract context workflows - Then I should find context_load workflow - And I should find context_auto workflow - And the workflows should include heuristics information - - Scenario: Extract execution workflows - When I extract execution workflows - Then I should find exec_command workflow - And I should find auto_debug workflow - And the workflows should include retry logic details - - Scenario: Calculate statistics - When I extract all workflows - Then the statistics should include total workflows - And the statistics should include workflows per category - And the statistics should include total Go components - And the statistics should include total Python modules - And the statistics should include test coverage metrics \ No newline at end of file diff --git a/robot/cloud_features.robot b/robot/cloud_features.robot deleted file mode 100644 index 3edef12ac..000000000 --- a/robot/cloud_features.robot +++ /dev/null @@ -1,63 +0,0 @@ -*** Settings *** -Documentation Integration tests for cloud features extraction -Resource discovery_common.resource -Library OperatingSystem -Library json_helper.py -Library Collections -Library String - -*** Variables *** -${CLOUD_YAML} ${OUTPUT_DIR}/cloud/cloud_features.yaml -${CLOUD_JSON} ${OUTPUT_DIR}/cloud/cloud_features.json -${CLOUD_MD} ${OUTPUT_DIR}/cloud/cloud_features.md - -*** Test Cases *** -Verify Cloud Features Extractor Runs Successfully - [Documentation] Test that the cloud features extractor completes without errors - [Tags] discovery - ${result}= Run Discovery Tool cloud_features - Should Be Successful ${result} - -Verify Cloud Features Files Generated - [Documentation] Test that all expected cloud features files are created - [Tags] discovery - File Should Exist ${CLOUD_YAML} - File Should Exist ${CLOUD_JSON} - File Should Exist ${CLOUD_MD} - -Validate Cloud Features JSON Structure - [Documentation] Verify that cloud features JSON has expected structure - [Tags] discovery - ${json_content}= Get File ${CLOUD_JSON} - ${data}= parse_json ${json_content} - - # Check main sections exist - Dictionary Should Contain Key ${data} cloud_features - Dictionary Should Contain Key ${data} statistics - Dictionary Should Contain Key ${data} replacements - -Validate Cloud Features Documentation - [Documentation] Verify the markdown documentation is comprehensive - [Tags] discovery - ${md_content}= Get File ${CLOUD_MD} - - # Check for key sections - Should Contain ${md_content} Cloud-Only Features Analysis - Should Contain ${md_content} Summary - Should Contain ${md_content} Replacement Strategies - -Validate Feature Statistics - [Documentation] Check that statistics are properly collected - [Tags] discovery - ${json_content}= Get File ${CLOUD_JSON} - ${data}= parse_json ${json_content} - - Dictionary Should Contain Key ${data} statistics - ${stats}= Set Variable ${data['statistics']} - - Dictionary Should Contain Key ${stats} total_features - Dictionary Should Contain Key ${stats} by_category - Dictionary Should Contain Key ${stats} by_action - - ${total}= Set Variable ${stats['total_features']} - Should Be True ${total} > 0 msg=Should have identified at least one cloud feature \ No newline at end of file diff --git a/robot/data_contracts.robot b/robot/data_contracts.robot deleted file mode 100644 index 0b4a1a0b4..000000000 --- a/robot/data_contracts.robot +++ /dev/null @@ -1,88 +0,0 @@ -*** Settings *** -Documentation Test data contract extraction from Plandex shared Go code -Library OperatingSystem -Library Collections -Library String -Library Process -Suite Setup Run Discovery Once - -*** Variables *** -${PYTHON} python -${PLANDEX_DIR} ${CURDIR}/../plandex -${OUTPUT_DIR} ${CURDIR}/../docs/reference/contracts -${PYTHON_SCRIPT} ${CURDIR}/../src/cleveragents/discovery/run_all.py - -*** Keywords *** -Run Discovery Once - [Documentation] Run the discovery script once for all tests - [Tags] discovery - ${result}= Run Process ${PYTHON} ${PYTHON_SCRIPT} cwd=${CURDIR}/.. - Should Be Equal As Integers ${result.rc} 0 - Set Suite Variable ${DISCOVERY_OUTPUT} ${result.stdout} - -*** Test Cases *** -Run Data Contract Extraction - [Documentation] Test running the full discovery script with data contracts - [Tags] discovery - Should Contain ${DISCOVERY_OUTPUT} Extracting Shared Data Contracts - Should Contain ${DISCOVERY_OUTPUT} ✓ Extracted contracts from - Should Contain ${DISCOVERY_OUTPUT} Structs: - Should Contain ${DISCOVERY_OUTPUT} Enums: - Should Contain ${DISCOVERY_OUTPUT} Type aliases: - -Verify JSON Contract Output - [Documentation] Test that JSON contract file is created - [Tags] discovery - File Should Exist ${OUTPUT_DIR}/data_contracts.json - ${size}= Get File Size ${OUTPUT_DIR}/data_contracts.json - Should Be True ${size} > 1000 JSON file too small: ${size} bytes - - # Basic structure check without full parsing - ${content}= Get File ${OUTPUT_DIR}/data_contracts.json - ${json_content}= Evaluate json.loads('''${content}''') json - - @{module_keys}= Get Dictionary Keys ${json_content} - Should Be True len(@{module_keys}) > 0 No modules found in contracts JSON - ${first_key}= Get From List ${module_keys} 0 - ${first_module}= Get From Dictionary ${json_content} ${first_key} - - Dictionary Should Contain Key ${first_module} structs - Dictionary Should Contain Key ${first_module} enums - Dictionary Should Contain Key ${first_module} type_aliases - Dictionary Should Contain Key ${first_module} package_name - -Verify Python Stubs Generation - [Documentation] Test that Python stub files are generated - [Tags] discovery - - Directory Should Exist ${OUTPUT_DIR}/stubs - @{files}= List Files In Directory ${OUTPUT_DIR}/stubs *.py - ${count}= Get Length ${files} - Should Be True ${count} > 0 No Python stubs generated - - # Check content of first stub file - ${first_file}= Get From List ${files} 0 - ${content}= Get File ${OUTPUT_DIR}/stubs/${first_file} - Should Contain ${content} from dataclasses import dataclass - Should Contain ${content} from typing import - -Verify Example Fixtures Generation - [Documentation] Test that example JSON fixtures are generated - [Tags] discovery - - Directory Should Exist ${OUTPUT_DIR}/fixtures - @{files}= List Files In Directory ${OUTPUT_DIR}/fixtures *.json - ${count}= Get Length ${files} - Should Be True ${count} > 0 No fixture files generated - - # Verify first fixture is valid JSON (basic check) - ${first_file}= Get From List ${files} 0 - ${content}= Get File ${OUTPUT_DIR}/fixtures/${first_file} - Should Contain ${content} { - Should Contain ${content} } - -Data Contract Performance Test - [Documentation] Test that contract extraction completes in reasonable time - [Tags] discovery - # This test is now covered by the suite setup timing - Should Contain ${DISCOVERY_OUTPUT} Discovery Summary \ No newline at end of file diff --git a/robot/discovery.robot b/robot/discovery.robot deleted file mode 100644 index 8daed16b8..000000000 --- a/robot/discovery.robot +++ /dev/null @@ -1,99 +0,0 @@ -*** Settings *** -Documentation Robot Framework tests for CleverAgents Discovery Tools -Library OperatingSystem -Library Process -Library String - -*** Variables *** -${PYTHON} python -${PROJECT_DIR} /app -${DISCOVERY_DIR} ${PROJECT_DIR}/src/cleveragents/discovery -${DOCS_DIR} ${PROJECT_DIR}/docs/reference - -*** Test Cases *** -Run Discovery Tool Suite - [Documentation] Test running the complete discovery tool suite - [Tags] discovery - ${result}= Run Process ${PYTHON} ${DISCOVERY_DIR}/run_all.py cwd=${PROJECT_DIR} - Should Contain ${result.stdout} CleverAgents Discovery Tool Suite - Should Contain ${result.stdout} ✓ Extracted - Should Contain ${result.stdout} commands - Should Be Equal As Integers ${result.rc} 0 - -Extract CLI Inventory - [Documentation] Test CLI inventory extraction directly - [Tags] discovery - ${result}= Run Process ${PYTHON} -m cleveragents.discovery.cli_inventory cwd=${PROJECT_DIR} - Should Contain ${result.stdout} Extracting CLI command metadata - Should Contain ${result.stdout} Extracted - Should Contain ${result.stdout} commands - Should Be Equal As Integers ${result.rc} 0 - -Verify Inventory Files Created - [Documentation] Verify that inventory files are created in the correct location - [Tags] discovery - File Should Exist ${DOCS_DIR}/cli_inventory.yaml - File Should Exist ${DOCS_DIR}/cli_inventory.json - - ${yaml_size}= Get File Size ${DOCS_DIR}/cli_inventory.yaml - ${json_size}= Get File Size ${DOCS_DIR}/cli_inventory.json - - Should Be True ${yaml_size} > 1000 YAML file too small - Should Be True ${json_size} > 1000 JSON file too small - -Validate YAML Inventory Structure - [Documentation] Check YAML inventory contains expected sections - [Tags] discovery - ${yaml_content}= Get File ${DOCS_DIR}/cli_inventory.yaml - Should Contain ${yaml_content} root: - Should Contain ${yaml_content} commands: - Should Contain ${yaml_content} hierarchy: - Should Contain ${yaml_content} metadata: - Should Contain ${yaml_content} statistics: - -Validate JSON Inventory Structure - [Documentation] Check JSON inventory contains expected sections - [Tags] discovery - ${json_content}= Get File ${DOCS_DIR}/cli_inventory.json - Should Contain ${json_content} "root" - Should Contain ${json_content} "commands" - Should Contain ${json_content} "hierarchy" - Should Contain ${json_content} "metadata" - Should Contain ${json_content} "statistics" - -Check Command Count - [Documentation] Verify minimum number of commands extracted - [Tags] discovery - ${json_content}= Get File ${DOCS_DIR}/cli_inventory.json - Should Match Regexp ${json_content} "total_commands":\\s*[6-9][0-9] At least 60 commands expected - -Discovery Tool Performance - [Documentation] Benchmark discovery tool performance - [Tags] discovery - ${start_time}= Get Time epoch - ${result}= Run Process ${PYTHON} -m cleveragents.discovery.cli_inventory cwd=${PROJECT_DIR} - ${end_time}= Get Time epoch - ${elapsed}= Evaluate ${end_time} - ${start_time} - - Log Discovery took ${elapsed} seconds - Should Be True ${elapsed} < 10 Discovery took too long (${elapsed}s) - Should Be Equal As Integers ${result.rc} 0 - -Test Import Discovery Module - [Documentation] Test that discovery module can be imported - [Tags] discovery - ${result}= Run Process ${PYTHON} -c import cleveragents.discovery; print('OK') cwd=${PROJECT_DIR} - Should Contain ${result.stdout} OK - Should Be Equal As Integers ${result.rc} 0 - -Test Discovery Module Has Expected Classes - [Documentation] Verify discovery module exports expected classes - [Tags] discovery - ${result}= Run Process ${PYTHON} -c from cleveragents.discovery import CLIInventoryExtractor, DataContractExtractor, EnvironmentVariableExtractor, ImplicitBehaviorExtractor, ServerEndpointExtractor, ShellAssetExtractor; print(' '.join([CLIInventoryExtractor.__name__, DataContractExtractor.__name__, EnvironmentVariableExtractor.__name__, ImplicitBehaviorExtractor.__name__, ServerEndpointExtractor.__name__, ShellAssetExtractor.__name__])) cwd=${PROJECT_DIR} - Should Contain ${result.stdout} CLIInventoryExtractor - Should Contain ${result.stdout} DataContractExtractor - Should Contain ${result.stdout} EnvironmentVariableExtractor - Should Contain ${result.stdout} ImplicitBehaviorExtractor - Should Contain ${result.stdout} ServerEndpointExtractor - Should Contain ${result.stdout} ShellAssetExtractor - Should Be Equal As Integers ${result.rc} 0 \ No newline at end of file diff --git a/robot/discovery_common.resource b/robot/discovery_common.resource deleted file mode 100644 index 130b163f4..000000000 --- a/robot/discovery_common.resource +++ /dev/null @@ -1,44 +0,0 @@ -*** Settings *** -Library OperatingSystem -Library Process -Library Collections - -*** Variables *** -${PLANDEX_DIR} ${CURDIR}/../plandex -${OUTPUT_DIR} ${CURDIR}/../docs/reference -${WORK_DIR} ${CURDIR}/.. - -*** Keywords *** -Setup Discovery Test - [Documentation] Common setup for discovery tests - Create Directory ${OUTPUT_DIR} - Log Working directory: ${WORK_DIR} - Log Plandex directory: ${PLANDEX_DIR} - Log Output directory: ${OUTPUT_DIR} - -Cleanup Discovery Test - [Documentation] Common cleanup for discovery tests - Log Test completed - -Run Discovery Tool - [Documentation] Run a specific discovery tool - [Arguments] ${tool_name} - ${result}= Run Process python -m cleveragents.discovery.${tool_name} cwd=${WORK_DIR} - RETURN ${result} - -Should Be Successful - [Documentation] Verify that a process result was successful - [Arguments] ${result} - Should Be Equal As Integers ${result.rc} 0 msg=Process failed with exit code ${result.rc} - -Should Be In - [Documentation] Verify that a value is in a list of valid values - [Arguments] ${value} @{valid_values} - ${found}= Set Variable ${FALSE} - FOR ${valid} IN @{valid_values} - IF '${value}' == '${valid}' - ${found}= Set Variable ${TRUE} - Exit For Loop - END - END - Should Be True ${found} msg=Value '${value}' not in valid values: @{valid_values} \ No newline at end of file diff --git a/robot/discovery_topic_progression_test.robot b/robot/discovery_topic_progression_test.robot deleted file mode 100644 index 25c488025..000000000 --- a/robot/discovery_topic_progression_test.robot +++ /dev/null @@ -1,186 +0,0 @@ -*** Settings *** -Documentation Test discovery stage topic progression bug fix -Library OperatingSystem -Library String -Library Collections -Library Process -Library DateTime -Suite Setup Setup Test Environment -Suite Teardown Cleanup Test Environment - -*** Settings *** -Resource v2_paths.resource - -*** Settings *** -Resource v2_paths.resource - -*** Variables *** -${CONFIG_PATH} ${CURDIR}/../examples/scientific_paper_writer.yaml -${CONTEXT_FILE} ${V2_CONTEXT_DIR}/discovery_stage_context.json -${CONTEXT_NAME} discovery_topic_test_ctx -${CONTEXT_DIR} ${TEMPDIR}/discovery_test_contexts -${UNIQUE_ID} ${EMPTY} - - -*** Test Cases *** -Discovery Stage Should Progress After Topic Is Set - [Documentation] Test that the discovery stage properly progresses when user provides a topic - - ${ctx_name} = Set Variable ${CONTEXT_NAME}_${UNIQUE_ID} - - # Start with a fresh context and move to discovery stage - Log Moving to discovery stage with !next command - ${result} = Run Process python -m cleveragents actor run - ... -c ${CONFIG_PATH} - ... --unsafe - ... --allow-rxpy-in-run-mode - ... --context ${ctx_name} - ... --context-dir ${CONTEXT_DIR} - ... -p !next discovery - ... cwd=/app - ... timeout=60s - Log Advanced to discovery: ${result.stdout} - Should Be Equal As Integers ${result.rc} 0 - # Verify we're now in discovery stage - ${stage_check}= Run Process python -m cleveragents actor run - ... -c ${CONFIG_PATH} - ... --unsafe - ... --allow-rxpy-in-run-mode - ... --context ${ctx_name} - ... --context-dir ${CONTEXT_DIR} - ... -p !stage - ... cwd=/app - ... timeout=20s - Should Contain ${stage_check.stdout} discovery - - # Set the topic with a clear, assertive statement - Log Setting topic with clear assertion - ${result} = Run Process python -m cleveragents actor run - ... -c ${CONFIG_PATH} - ... --unsafe - ... --allow-rxpy-in-run-mode - ... --context ${ctx_name} - ... --context-dir ${CONTEXT_DIR} - ... -p The topic is: tobacco and its effects on the lungs. That is the complete topic, no additional details needed. - ... cwd=/app - ... timeout=60s - Log First response: ${result.stdout} - - # Check if we progressed to asking about length (next question in discovery) - ${has_length_question} = Run Keyword And Return Status - ... Should Contain Any ${result.stdout} length word count how long pages - - # If we didn't progress, be even more aggressive - IF not ${has_length_question} - Log Did not progress, being more assertive - ${result} = Run Process python -m cleveragents actor run - ... -c ${CONFIG_PATH} - ... --unsafe - ... --allow-rxpy-in-run-mode - ... --context ${ctx_name} - ... --context-dir ${CONTEXT_DIR} - ... -p I already told you the topic: tobacco and its effects on the lungs. Please accept this topic and move on to the next question. I do not need to provide any more clarification. - ... cwd=/app - ... timeout=60s - Log Second response: ${result.stdout} - END - - # Now verify we progressed to the length question - Should Contain Any ${result.stdout} - ... length - ... word count - ... how long - ... pages - ... msg=Expected to progress to length question but got: ${result.stdout} - - # Verify the topic was actually set in context by checking the global_context.json file directly - ${context_file} = Set Variable ${CONTEXT_DIR}/${ctx_name}/global_context.json - ${context_content} = OperatingSystem.Get File ${context_file} - Log Context file content: ${context_content} - - # Check that topic is not null in the context - Should Contain ${context_content} "topic" - Should Not Contain ${context_content} "topic": null - -Discovery Stage Should Handle Multiple Clarifications Before Progressing - [Documentation] Test that the discovery stage can handle multiple rounds of clarification - - ${ctx_name} = Set Variable ${CONTEXT_NAME}_multi_${UNIQUE_ID} - - # Start with a fresh context and move to discovery stage - Log Moving to discovery stage with !next command - ${result} = Run Process python -m cleveragents actor run - ... -c ${CONFIG_PATH} - ... --unsafe - ... --allow-rxpy-in-run-mode - ... --context ${ctx_name} - ... --context-dir ${CONTEXT_DIR} - ... -p !next discovery - ... cwd=/app - ... timeout=60s - Should Be Equal As Integers ${result.rc} 0 - # Verify we're now in discovery stage - ${stage_check}= Run Process python -m cleveragents actor run - ... -c ${CONFIG_PATH} - ... --unsafe - ... --allow-rxpy-in-run-mode - ... --context ${ctx_name} - ... --context-dir ${CONTEXT_DIR} - ... -p !stage - ... cwd=/app - ... timeout=20s - Should Contain ${stage_check.stdout} discovery - - # First attempt - start with a clear, complete statement - Log Setting topic with clear statement - ${result} = Run Process python -m cleveragents actor run - ... -c ${CONFIG_PATH} - ... --unsafe - ... --allow-rxpy-in-run-mode - ... --context ${ctx_name} - ... --context-dir ${CONTEXT_DIR} - ... -p The topic is tobacco and its effects on lung health. This is the complete topic description. - ... cwd=/app - ... timeout=60s - Log Topic response: ${result.stdout} - - # Check if we progressed or need another clarification - ${has_length_question} = Run Keyword And Return Status - ... Should Contain Any ${result.stdout} length word count how long - - # If still asking questions, be very assertive - IF not ${has_length_question} - Log Being more assertive about the topic - ${result} = Run Process python -m cleveragents actor run - ... -c ${CONFIG_PATH} - ... --unsafe - ... --allow-rxpy-in-run-mode - ... --context ${ctx_name} - ... --context-dir ${CONTEXT_DIR} - ... -p I have already provided the topic: tobacco and its effects on lung health. That is all the information about the topic. Please accept it and proceed to the next question. - ... cwd=/app - ... timeout=60s - Log Assertive response: ${result.stdout} - END - - # Now verify we eventually progressed - Should Contain Any ${result.stdout} - ... length - ... word count - ... how long - ... msg=Expected to eventually progress to length question - -*** Keywords *** -Setup Test Environment - Require OpenAI Key - ${timestamp} = Get Current Date result_format=%Y%m%d_%H%M%S - ${random} = Evaluate random.randint(1000, 9999) modules=random - Set Suite Variable ${UNIQUE_ID} ${timestamp}_${random} - Create Directory ${CONTEXT_DIR} - -Cleanup Test Environment - Run Keyword And Ignore Error Remove Directory ${CONTEXT_DIR} recursive=True - -Require OpenAI Key - ${api_key}= Get Environment Variable OPENAI_API_KEY default= - Run Keyword If '${api_key}' == '' Skip OPENAI_API_KEY not set; skipping LLM integration tests diff --git a/robot/env_variables.robot b/robot/env_variables.robot deleted file mode 100644 index 06eef750b..000000000 --- a/robot/env_variables.robot +++ /dev/null @@ -1,151 +0,0 @@ -*** Settings *** -Documentation Test environment variable extraction from Plandex -Library OperatingSystem -Library Collections -Library String -Resource discovery_common.resource - -*** Variables *** -${PYTHON} python -${ENV_JSON} ${OUTPUT_DIR}/env_variables.json -${ENV_YAML} ${OUTPUT_DIR}/env_variables.yaml -${ENV_MAPPING} ${OUTPUT_DIR}/env_mapping.txt -${ENV_GUIDE} ${OUTPUT_DIR}/env_migration_guide.md - -*** Test Cases *** -Extract Environment Variables from Documentation - [Documentation] Extract environment variables from documentation files - [Tags] discovery environment - - # Run extraction - ${result}= Run Process ${PYTHON} -m cleveragents.discovery.env_variables - ... ${PLANDEX_DIR} --output ${OUTPUT_DIR} - ... cwd=${WORK_DIR} - - Should Be Equal As Integers ${result.returncode} 0 - Should Contain ${result.stdout} Environment variable extraction complete - - # Verify output files exist - File Should Exist ${ENV_JSON} - File Should Exist ${ENV_YAML} - File Should Exist ${ENV_MAPPING} - File Should Exist ${ENV_GUIDE} - -Validate Environment Variable JSON Structure - [Documentation] Validate the structure of extracted environment variables - [Tags] discovery environment - - ${json_content}= Get File ${ENV_JSON} - ${data}= Evaluate json.loads('''${json_content}''') json - - # Check required keys - Dictionary Should Contain Key ${data} variables - Dictionary Should Contain Key ${data} conflicts - Dictionary Should Contain Key ${data} mapping - Dictionary Should Contain Key ${data} statistics - - # Check statistics - ${stats}= Get From Dictionary ${data} statistics - Dictionary Should Contain Key ${stats} total_variables - Dictionary Should Contain Key ${stats} documented_variables - Dictionary Should Contain Key ${stats} code_only_variables - Dictionary Should Contain Key ${stats} migration_required - - # Verify we found variables - ${total}= Get From Dictionary ${stats} total_variables - Should Be True ${total} > 0 Should find environment variables - -Check Variable Naming Conventions - [Documentation] Verify variable naming conventions and mappings - [Tags] discovery environment - - ${json_content}= Get File ${ENV_JSON} - ${data}= Evaluate json.loads('''${json_content}''') json - ${mapping}= Get From Dictionary ${data} mapping - - # Check PLANDEX to CLEVERAGENTS mapping - FOR ${old_name} IN @{mapping.keys()} - ${new_name}= Get From Dictionary ${mapping} ${old_name} - Run Keyword If '${old_name}'.startswith('PLANDEX_') - ... Should Start With ${new_name} CLEVERAGENTS_ - END - -Validate Migration Guide Content - [Documentation] Verify migration guide has expected content - [Tags] discovery environment - - ${content}= Get File ${ENV_GUIDE} - - # Check headers - Should Contain ${content} \# Environment Variable Migration Guide - Should Contain ${content} \#\# Overview - Should Contain ${content} \#\# Variable Mappings - Should Contain ${content} \#\# Conflicts and Warnings - - # Check table format - Should Contain ${content} | Old Name | New Name | - Should Contain ${content} |----------|----------| - - # Check statistics - Should Contain ${content} Total variables: - Should Contain ${content} Variables requiring migration: - -Environment Variable Categories - [Documentation] Check that variables are properly categorized - [Tags] discovery environment - - ${json_content}= Get File ${ENV_JSON} - ${data}= Evaluate json.loads('''${json_content}''') json - ${variables}= Get From Dictionary ${data} variables - - ${categories}= Create List - FOR ${var_name} ${var_info} IN &{variables} - ${category}= Get From Dictionary ${var_info} category - Append To List ${categories} ${category} - END - - # Remove duplicates - ${unique_categories}= Remove Duplicates ${categories} - - # Should have multiple categories - ${length}= Get Length ${unique_categories} - Should Be True ${length} > 1 Should have multiple categories - - # Check for expected categories - ${expected}= Create List CLI Server LLM Providers General - FOR ${cat} IN @{expected} - ${found}= Run Keyword And Return Status List Should Contain Value ${unique_categories} ${cat} - Log Category ${cat}: ${found} - END - -Provider Variables Preservation - [Documentation] Verify provider-specific variables are preserved - [Tags] discovery environment - - ${json_content}= Get File ${ENV_JSON} - ${data}= Evaluate json.loads('''${json_content}''') json - ${variables}= Get From Dictionary ${data} variables - - # Check provider variables - ${providers}= Create List OPENAI_ ANTHROPIC_ GEMINI_ AZURE_ AWS_ - - FOR ${prefix} IN @{providers} - ${provider_vars}= Create List - FOR ${var_name} ${var_info} IN &{variables} - Run Keyword If '${var_name}'.startswith('${prefix}') - ... Append To List ${provider_vars} ${var_name} - END - - # Check that provider variables keep their names - FOR ${var} IN @{provider_vars} - ${var_info}= Get From Dictionary ${variables} ${var} - ${proposed}= Get From Dictionary ${var_info} proposed_cleveragents_name - Should Be Equal ${var} ${proposed} Provider variable should keep its name - END - END - -*** Keywords *** -Run Process - [Arguments] @{args} &{config} - ${result}= Evaluate subprocess.run(${args}, capture_output=True, text=True, **${config}) subprocess - RETURN ${result} \ No newline at end of file diff --git a/robot/implicit_behaviors.robot b/robot/implicit_behaviors.robot deleted file mode 100644 index bce83d524..000000000 --- a/robot/implicit_behaviors.robot +++ /dev/null @@ -1,108 +0,0 @@ -*** Settings *** -Documentation Robot Framework tests for implicit behaviors extraction -Library OperatingSystem -Library Collections -Library String -Library Process -Library BuiltIn -Resource discovery_common.resource -Suite Setup Run Discovery Once - -*** Variables *** -${PYTHON} python -${WORK_DIR} ${CURDIR}/.. -${PYTHON_SCRIPT} ${WORK_DIR}/src/cleveragents/discovery/run_all.py -${OUTPUT_DIR} ${WORK_DIR}/docs/reference/behaviors -${OUTPUT_JSON} ${OUTPUT_DIR}/implicit_behaviors.json -${OUTPUT_YAML} ${OUTPUT_DIR}/implicit_behaviors.yaml -${OUTPUT_MD} ${OUTPUT_DIR}/implicit_behaviors.md - -*** Keywords *** -Run Discovery Once - [Documentation] Execute discovery script once for all tests - ${result}= Run Process ${PYTHON} ${PYTHON_SCRIPT} cwd=${WORK_DIR} - Should Be Equal As Integers ${result.rc} 0 - Should Contain ${result.stdout} Extracting Implicit Runtime Behaviors - Set Suite Variable ${DISCOVERY_RAN} ${TRUE} - -*** Test Cases *** -Extract Implicit Behaviors Successfully - [Documentation] Test that implicit behaviors can be extracted from Plandex - [Tags] discovery behaviors - - Should Be True ${DISCOVERY_RAN} Discovery did not run - - File Should Exist ${OUTPUT_JSON} - File Should Exist ${OUTPUT_YAML} - File Should Exist ${OUTPUT_MD} - -Validate Behavior Categories - [Documentation] Verify that all expected behavior categories are found - [Tags] discovery behaviors validation - - ${content}= Get File ${OUTPUT_JSON} - Should Contain ${content} "locking" - Should Contain ${content} "retry" - Should Contain ${content} "validation" - Should Contain ${content} "concurrency" - Should Contain ${content} "streaming" - Should Contain ${content} "telemetry" - -Check Behavior Details - [Documentation] Verify that behaviors have required details - [Tags] discovery behaviors structure - - ${content}= Get File ${OUTPUT_JSON} - Should Contain ${content} "behaviors" - Should Contain ${content} "name" - Should Contain ${content} "category" - Should Contain ${content} "description" - Should Contain ${content} "python_considerations" - -Verify Sequence Diagrams - [Documentation] Check that sequence diagrams are generated - [Tags] discovery behaviors diagrams - - ${content}= Get File ${OUTPUT_JSON} - Should Contain ${content} "sequence_diagrams" - Should Contain ${content} "auto_context_loading" - Should Contain ${content} "retry_with_backoff" - Should Contain ${content} "git_locking" - -Check Migration Considerations - [Documentation] Verify Python migration considerations are collected - [Tags] discovery behaviors migration - - ${content}= Get File ${OUTPUT_JSON} - Should Contain ${content} "python_migration_considerations" - - ${md_content}= Get File ${OUTPUT_MD} - Should Contain ${md_content} asyncio - Should Contain Any ${md_content} threading thread - Should Contain Any ${md_content} pydantic marshmallow validat - -Check Behavior Location References - [Documentation] Verify that behaviors include file:line references - [Tags] discovery behaviors references - - ${content}= Get File ${OUTPUT_JSON} - Should Match Regexp ${content} .+\\.go:\\d+ - -Performance Test For Behavior Extraction - [Documentation] Ensure behavior extraction completes in reasonable time - [Tags] discovery behaviors performance - - # This test is covered by the suite setup - Should Be True ${DISCOVERY_RAN} Discovery did not run - -*** Keywords *** -Should Contain Any - [Arguments] ${text} @{patterns} - [Documentation] Check if text contains any of the patterns - - ${found}= Set Variable ${FALSE} - FOR ${pattern} IN @{patterns} - ${contains}= Run Keyword And Return Status Should Contain ${text} ${pattern} - ${found}= Set Variable If ${contains} ${TRUE} ${found} - END - Should Be True ${found} Text does not contain any of: @{patterns} diff --git a/robot/server_endpoints.robot b/robot/server_endpoints.robot deleted file mode 100644 index 414babe47..000000000 --- a/robot/server_endpoints.robot +++ /dev/null @@ -1,135 +0,0 @@ -*** Settings *** - -*** Variables *** -${PYTHON} python -Documentation Test suite for server endpoint discovery functionality -Library OperatingSystem -Library Collections -Library Process - -*** Test Cases *** -Server Endpoint Extraction Should Work - [Documentation] Test that server endpoint extraction runs successfully - [Tags] discovery - ${result}= Run Process ${PYTHON} -m cleveragents.discovery.server_endpoints cwd=/app - Should Be Equal As Integers ${result.rc} 0 - Should Contain ${result.stdout} Server Endpoint Extraction Complete - Should Contain ${result.stdout} Total endpoints: - Should Contain ${result.stdout} Streaming endpoints: - -Server Endpoint Files Should Be Created - [Documentation] Verify that all expected output files are created - [Tags] discovery - File Should Exist /app/docs/reference/server_endpoints.yaml - File Should Exist /app/docs/reference/server_endpoints.json - File Should Exist /app/docs/reference/server_api.yaml - -Server Endpoint JSON Should Be Valid - [Documentation] Test that generated JSON is valid and contains expected structure - [Tags] discovery - ${json_content}= Load JSON From File /app/docs/reference/server_endpoints.json - Dictionary Should Contain Key ${json_content} metadata - Dictionary Should Contain Key ${json_content} statistics - Dictionary Should Contain Key ${json_content} endpoints_by_category - Dictionary Should Contain Key ${json_content} all_endpoints - - ${stats}= Get From Dictionary ${json_content} statistics - Dictionary Should Contain Key ${stats} total_endpoints - Dictionary Should Contain Key ${stats} streaming_endpoints - Dictionary Should Contain Key ${stats} categories - Dictionary Should Contain Key ${stats} methods - -Server OpenAPI Spec Should Be Valid - [Documentation] Test that OpenAPI spec is valid YAML with correct structure - [Tags] discovery - ${yaml_content}= Get File /app/docs/reference/server_api.yaml - Should Contain ${yaml_content} openapi: - Should Contain ${yaml_content} info: - Should Contain ${yaml_content} paths: - Should Contain ${yaml_content} components: - -Server Endpoint Count Should Be Reasonable - [Documentation] Verify that a reasonable number of endpoints were extracted - [Tags] discovery - ${json_content}= Load JSON From File /app/docs/reference/server_endpoints.json - ${stats}= Get From Dictionary ${json_content} statistics - ${total}= Get From Dictionary ${stats} total_endpoints - Should Be True ${total} >= 80 Expected at least 80 endpoints, got ${total} - -Streaming Endpoints Should Be Identified - [Documentation] Verify that streaming endpoints are properly identified - [Tags] discovery - ${json_content}= Load JSON From File /app/docs/reference/server_endpoints.json - ${stats}= Get From Dictionary ${json_content} statistics - ${streaming}= Get From Dictionary ${stats} streaming_endpoints - Should Be True ${streaming} >= 3 Expected at least 3 streaming endpoints, got ${streaming} - -Endpoint Categories Should Be Comprehensive - [Documentation] Verify that endpoints are properly categorized - [Tags] discovery - ${json_content}= Load JSON From File /app/docs/reference/server_endpoints.json - ${categories}= Get From Dictionary ${json_content} endpoints_by_category - - Dictionary Should Contain Key ${categories} Authentication - Dictionary Should Contain Key ${categories} Plans - Dictionary Should Contain Key ${categories} Projects - Dictionary Should Contain Key ${categories} Models - Dictionary Should Contain Key ${categories} Organizations - Dictionary Should Contain Key ${categories} System - - ${auth_endpoints}= Get From Dictionary ${categories} Authentication - ${length}= Get Length ${auth_endpoints} - Should Be True ${length} > 0 Authentication category should have endpoints - -HTTP Methods Should Be Diverse - [Documentation] Verify that various HTTP methods are extracted - [Tags] discovery - ${json_content}= Load JSON From File /app/docs/reference/server_endpoints.json - ${stats}= Get From Dictionary ${json_content} statistics - ${methods}= Get From Dictionary ${stats} methods - - Dictionary Should Contain Key ${methods} GET - Dictionary Should Contain Key ${methods} POST - Dictionary Should Contain Key ${methods} PUT - Dictionary Should Contain Key ${methods} DELETE - Dictionary Should Contain Key ${methods} PATCH - -Path Parameters Should Be Extracted - [Documentation] Verify that path parameters are properly extracted - [Tags] discovery - ${json_content}= Load JSON From File /app/docs/reference/server_endpoints.json - ${endpoints}= Get From Dictionary ${json_content} all_endpoints - - ${params_found}= Set Variable ${False} - ${planId_found}= Set Variable ${False} - ${projectId_found}= Set Variable ${False} - - FOR ${endpoint} IN @{endpoints} - ${has_params}= Run Keyword And Return Status - ... Dictionary Should Contain Key ${endpoint} path_params - IF ${has_params} - ${params}= Get From Dictionary ${endpoint} path_params - ${length}= Get Length ${params} - IF ${length} > 0 - ${params_found}= Set Variable ${True} - ${param_str}= Convert To String ${params} - IF 'planId' in $param_str - ${planId_found}= Set Variable ${True} - END - IF 'projectId' in $param_str - ${projectId_found}= Set Variable ${True} - END - END - END - END - - Should Be True ${params_found} No endpoints with path parameters found - Should Be True ${planId_found} planId parameter not found in any endpoint - Should Be True ${projectId_found} projectId parameter not found in any endpoint - -*** Keywords *** -Load JSON From File - [Arguments] ${file_path} - ${content}= Get File ${file_path} - ${json}= Evaluate json.loads('''${content}''') json - RETURN ${json} \ No newline at end of file diff --git a/robot/shell_assets.robot b/robot/shell_assets.robot deleted file mode 100644 index 31c125f63..000000000 --- a/robot/shell_assets.robot +++ /dev/null @@ -1,133 +0,0 @@ -*** Settings *** -Documentation Integration tests for shell asset extraction -Library Collections -Library OperatingSystem -Library Process -Library String - -*** Variables *** -${PYTHON} python -${SHELL_ASSETS_JSON} docs/reference/shell_assets.json -${SHELL_ASSETS_YAML} docs/reference/shell_assets.yaml -${WRAPPERS_DIR} docs/reference/shell_wrappers - -*** Test Cases *** -Run Shell Asset Extraction - [Documentation] Test running the shell asset extraction tool - [Tags] discovery shell - ${result}= Run Process ${PYTHON} -m cleveragents.discovery.shell_assets cwd=${CURDIR}/.. - Should Be Equal As Numbers ${result.rc} 0 - Should Contain ${result.stdout} Shell Asset Extraction Summary - Should Contain ${result.stdout} Total scripts found - -Verify Shell Asset Catalog Files - [Documentation] Verify that shell asset catalog files are created - [Tags] discovery shell - File Should Exist ${SHELL_ASSETS_JSON} - File Should Exist ${SHELL_ASSETS_YAML} - - ${json_content}= Get File ${SHELL_ASSETS_JSON} - ${catalog}= Evaluate json.loads('''${json_content}''') json - - Dictionary Should Contain Key ${catalog} scripts - Dictionary Should Contain Key ${catalog} environment_map - Dictionary Should Contain Key ${catalog} statistics - -Analyze Start Local Script - [Documentation] Verify start_local.sh analysis - [Tags] discovery shell - ${json_content}= Get File ${SHELL_ASSETS_JSON} - ${catalog}= Evaluate json.loads('''${json_content}''') json - - ${scripts}= Get From Dictionary ${catalog} scripts - ${start_local}= Set Variable ${NONE} - - FOR ${script} IN @{scripts} - ${name}= Get From Dictionary ${script} name - IF '${name}' == 'start_local.sh' - ${start_local}= Set Variable ${script} - Exit For Loop - END - END - - Should Not Be Equal ${start_local} ${NONE} start_local.sh not found - - ${requires_docker}= Get From Dictionary ${start_local} requires_docker - ${requires_git}= Get From Dictionary ${start_local} requires_git - ${python_replacement}= Get From Dictionary ${start_local} python_replacement_suggested - - Should Be True ${requires_docker} - Should Be True ${requires_git} - Should Be True ${python_replacement} - -Check Environment Variables - [Documentation] Verify environment variables are extracted - [Tags] discovery shell - ${json_content}= Get File ${SHELL_ASSETS_JSON} - ${catalog}= Evaluate json.loads('''${json_content}''') json - - ${env_map}= Get From Dictionary ${catalog} environment_map - ${env_count}= Get Length ${env_map} - Should Be True ${env_count} > 0 No environment variables found - - # Check that each variable maps to scripts - FOR ${var} ${scripts} IN &{env_map} - ${script_count}= Get Length ${scripts} - Should Be True ${script_count} > 0 Variable ${var} has no scripts - END - -Verify Script Statistics - [Documentation] Verify shell script statistics - [Tags] discovery shell - ${json_content}= Get File ${SHELL_ASSETS_JSON} - ${catalog}= Evaluate json.loads('''${json_content}''') json - - ${stats}= Get From Dictionary ${catalog} statistics - - Dictionary Should Contain Key ${stats} total_scripts - Dictionary Should Contain Key ${stats} docker_required - Dictionary Should Contain Key ${stats} git_required - Dictionary Should Contain Key ${stats} idempotent - Dictionary Should Contain Key ${stats} python_replacement - - ${total}= Get From Dictionary ${stats} total_scripts - Should Be True ${total} > 0 No scripts found - -Check Python Wrappers - [Documentation] Verify Python wrapper generation - [Tags] discovery shell - ${wrapper_exists}= Run Keyword And Return Status Directory Should Exist ${WRAPPERS_DIR} - - Run Keyword If ${wrapper_exists} - ... Check Wrapper Files - -Validate Catalog Consistency - [Documentation] Ensure JSON and YAML catalogs contain the same data - [Tags] discovery shell - ${json_content}= Get File ${SHELL_ASSETS_JSON} - ${json_data}= Evaluate json.loads('''${json_content}''') json - - ${yaml_content}= Get File ${SHELL_ASSETS_YAML} - ${yaml_data}= Evaluate yaml.safe_load('''${yaml_content}''') yaml - - # Compare script counts - ${json_scripts}= Get From Dictionary ${json_data} scripts - ${yaml_scripts}= Get From Dictionary ${yaml_data} scripts - ${json_count}= Get Length ${json_scripts} - ${yaml_count}= Get Length ${yaml_scripts} - Should Be Equal As Numbers ${json_count} ${yaml_count} - -*** Keywords *** -Check Wrapper Files - [Documentation] Check Python wrapper files if directory exists - @{wrappers}= List Files In Directory ${WRAPPERS_DIR} *.py - ${wrapper_count}= Get Length ${wrappers} - - Should Be True ${wrapper_count} > 0 No Python wrappers found - - FOR ${wrapper} IN @{wrappers} - ${content}= Get File ${WRAPPERS_DIR}/${wrapper} - Should Contain ${content} def run_ - Should Contain ${content} subprocess.run - Should Contain Any ${content} """ ''' - END \ No newline at end of file diff --git a/robot/workflow_parity.robot b/robot/workflow_parity.robot deleted file mode 100644 index a5c27bb95..000000000 --- a/robot/workflow_parity.robot +++ /dev/null @@ -1,62 +0,0 @@ -*** Settings *** -Documentation Integration tests for workflow parity matrix extraction -Resource discovery_common.resource -Library OperatingSystem -Library json_helper.py -Library Collections -Library String - -*** Variables *** -${PARITY_YAML} ${OUTPUT_DIR}/workflows/workflow_parity.yaml -${PARITY_JSON} ${OUTPUT_DIR}/workflows/workflow_parity.json -${PARITY_MD} ${OUTPUT_DIR}/workflows/workflow_parity.md - -*** Test Cases *** -Verify Workflow Parity Extractor Runs Successfully - [Documentation] Test that the workflow parity extractor completes without errors - [Tags] discovery - ${result}= Run Discovery Tool workflow_parity - Should Be Successful ${result} - -Verify Workflow Parity Files Generated - [Documentation] Test that all expected workflow parity files are created - [Tags] discovery - File Should Exist ${PARITY_YAML} - File Should Exist ${PARITY_JSON} - File Should Exist ${PARITY_MD} - -Validate Workflow JSON Structure - [Documentation] Verify that workflow JSON has expected structure - [Tags] discovery - ${json_content}= Get File ${PARITY_JSON} - ${data}= parse_json ${json_content} - - # Check main sections exist - Dictionary Should Contain Key ${data} workflows - Dictionary Should Contain Key ${data} categories - Dictionary Should Contain Key ${data} statistics - Dictionary Should Contain Key ${data} matrix - -Validate Parity Matrix Documentation - [Documentation] Verify the markdown documentation is comprehensive - [Tags] discovery - ${md_content}= Get File ${PARITY_MD} - - # Check for key sections - Should Contain ${md_content} Workflow Parity Matrix - Should Contain ${md_content} Summary Statistics - Should Contain ${md_content} Workflows by Category - -Validate Parity Statistics - [Documentation] Check that statistics are properly collected - [Tags] discovery - ${json_content}= Get File ${PARITY_JSON} - ${data}= parse_json ${json_content} - - Dictionary Should Contain Key ${data} statistics - ${stats}= Set Variable ${data['statistics']} - - Dictionary Should Contain Key ${stats} total_workflows - - ${total}= Set Variable ${stats['total_workflows']} - Should Be True ${total} > 0 msg=Should have extracted at least one workflow \ No newline at end of file diff --git a/src/cleveragents/core/retry_patterns.py b/src/cleveragents/core/retry_patterns.py index f7e7d7997..6d4226f58 100644 --- a/src/cleveragents/core/retry_patterns.py +++ b/src/cleveragents/core/retry_patterns.py @@ -1,8 +1,7 @@ """Retry patterns implementation using tenacity library. -This module implements the 33 retry patterns discovered from the Plandex codebase, -providing async-first retry capabilities with exponential backoff, circuit breakers, -and configurable retry strategies. +This module implements 33 retry patterns, providing async-first retry capabilities +with exponential backoff, circuit breakers, and configurable retry strategies. Based on Phase 0 discovery: 33 retry patterns found in Go code need Python equivalents. """ diff --git a/src/cleveragents/discovery/__init__.py b/src/cleveragents/discovery/__init__.py deleted file mode 100644 index 5b78314bc..000000000 --- a/src/cleveragents/discovery/__init__.py +++ /dev/null @@ -1,17 +0,0 @@ -"""Discovery tools for extracting metadata from the plandex Go codebase.""" - -from .cli_inventory import CLIInventoryExtractor -from .data_contracts import DataContractExtractor -from .env_variables import EnvironmentVariableExtractor -from .implicit_behaviors import ImplicitBehaviorExtractor -from .server_endpoints import ServerEndpointExtractor -from .shell_assets import ShellAssetExtractor - -__all__ = [ - "CLIInventoryExtractor", - "DataContractExtractor", - "EnvironmentVariableExtractor", - "ImplicitBehaviorExtractor", - "ServerEndpointExtractor", - "ShellAssetExtractor", -] diff --git a/src/cleveragents/discovery/cli_inventory.py b/src/cleveragents/discovery/cli_inventory.py deleted file mode 100644 index 51a24f9a7..000000000 --- a/src/cleveragents/discovery/cli_inventory.py +++ /dev/null @@ -1,357 +0,0 @@ -"""CLI Inventory Extractor for Plandex Go codebase. - -This module parses the Plandex CLI Go source code to extract command metadata -including names, aliases, flags, help text, and more. The extracted data is -saved as structured YAML/JSON for use in the Python migration. -""" - -import json -import re -from pathlib import Path -from typing import Any - -import yaml -from pydantic import BaseModel, ConfigDict, Field - - -class Flag(BaseModel): - """Represents a CLI flag.""" - - name: str - shorthand: str = "" - flag_type: str = "string" - default_value: Any | None = None - description: str = "" - required: bool = False - global_flag: bool = False - - model_config = ConfigDict(validate_assignment=True) - - -def _empty_flag_list() -> list[Flag]: - return [] - - -def _empty_str_list() -> list[str]: - return [] - - -class Command(BaseModel): - """Represents a CLI command.""" - - name: str - use: str = "" - aliases: list[str] = Field(default_factory=_empty_str_list) - short_description: str = "" - long_description: str = "" - flags: list[Flag] = Field(default_factory=_empty_flag_list) - subcommands: list[str] = Field(default_factory=_empty_str_list) - parent: str | None = None - run_function: str | None = None - file_path: str = "" - requires_auth: bool = False - requires_project: bool = False - requires_plan: bool = False - hidden: bool = False - - model_config = ConfigDict(validate_assignment=True) - - -class CLIInventoryExtractor: - """Extracts CLI command metadata from Plandex Go source code.""" - - def __init__(self, plandex_dir: Path | str = Path("/app/plandex")): - self.plandex_dir = ( - Path(plandex_dir) if isinstance(plandex_dir, str) else plandex_dir - ) - self.cli_cmd_dir = self.plandex_dir / "app" / "cli" / "cmd" - self.commands: dict[str, Command] = {} - self.root_command: Command | None = None - - def extract_all(self) -> dict[str, Any]: - """Extract all CLI command metadata from the Plandex codebase.""" - # First extract the root command - self._extract_root_command() - - # Then extract all other commands - for go_file in self.cli_cmd_dir.glob("*.go"): - if go_file.name == "root.go": - continue # Already processed - self._extract_command_from_file(go_file) - - # Build the command hierarchy - hierarchy = self._build_command_hierarchy() - - # Extract additional metadata - metadata = self._extract_additional_metadata() - - return { - "root": self.root_command.model_dump() if self.root_command else None, - "commands": {name: cmd.model_dump() for name, cmd in self.commands.items()}, - "hierarchy": hierarchy, - "metadata": metadata, - "statistics": self._gather_statistics(), - } - - def _extract_root_command(self) -> None: - """Extract the root command from root.go.""" - root_file = self.cli_cmd_dir / "root.go" - if not root_file.exists(): - return - - content = root_file.read_text() - - # Extract RootCmd definition - root_cmd_pattern = r"var\s+RootCmd\s*=\s*&cobra\.Command\{([^}]+)\}" - match = re.search(root_cmd_pattern, content, re.DOTALL) - if match: - cmd_body = match.group(1) - self.root_command = self._parse_command_struct( - cmd_body, "root", str(root_file) - ) - - # Find commands added to root - add_command_pattern = r"RootCmd\.AddCommand\((\w+)\)" - for match in re.finditer(add_command_pattern, content): - cmd_var = match.group(1) - if self.root_command: - self.root_command.subcommands.append(cmd_var) - - def _extract_command_from_file(self, go_file: Path) -> None: - """Extract command definitions from a single Go file.""" - content = go_file.read_text() - - # Find all cobra.Command definitions - cmd_pattern = r"var\s+(\w+Cmd)\s*=\s*&cobra\.Command\{([^}]+)\}" - for match in re.finditer(cmd_pattern, content, re.DOTALL): - cmd_var = match.group(1) - cmd_body = match.group(2) - - # Parse the command name from the variable name - cmd_name = self._var_to_cmd_name(cmd_var) - - # Parse the command struct - cmd = self._parse_command_struct(cmd_body, cmd_name, str(go_file)) - - # Check for auth requirements - if "auth.MustResolveAuthWithOrg()" in content: - cmd.requires_auth = True - if "lib.MustResolveProject()" in content: - cmd.requires_project = True - if "lib.CurrentPlanId" in content: - cmd.requires_plan = True - - # Extract flags defined in init() function - init_pattern = r"func\s+init\(\)\s*\{([^}]+)\}" - init_match = re.search(init_pattern, content, re.DOTALL) - if init_match: - init_body = init_match.group(1) - flags = self._extract_flags_from_init(init_body, cmd_var) - cmd.flags.extend(flags) - - self.commands[cmd_name] = cmd - - def _parse_command_struct( - self, cmd_body: str, cmd_name: str, file_path: str - ) -> Command: - """Parse a cobra.Command struct body.""" - cmd = Command(name=cmd_name, file_path=file_path) - - # Extract Use - use_match = re.search(r'Use:\s*["`]([^"`]+)["`]', cmd_body) - if use_match: - cmd.use = use_match.group(1).strip() - - # Extract Aliases - aliases_match = re.search(r"Aliases:\s*\[\]string\{([^}]+)\}", cmd_body) - if aliases_match: - aliases_str = aliases_match.group(1) - cmd.aliases = [a.strip('" ') for a in aliases_str.split(",")] - - # Extract Short description - short_match = re.search(r'Short:\s*["`]([^"`]+)["`]', cmd_body) - if short_match: - cmd.short_description = short_match.group(1).strip() - - # Extract Long description - long_match = re.search(r'Long:\s*["`]([^"`]+)["`]', cmd_body) - if long_match: - cmd.long_description = long_match.group(1).strip() - - # Extract Hidden flag - if re.search(r"Hidden:\s*true", cmd_body): - cmd.hidden = True - - # Extract Run function - run_match = re.search(r"Run:\s*(\w+)", cmd_body) - if run_match: - cmd.run_function = run_match.group(1) - - return cmd - - def _extract_flags_from_init(self, init_body: str, cmd_var: str) -> list[Flag]: - """Extract flag definitions from init() function body.""" - flags: list[Flag] = [] - - # Pattern for flag definitions - flag_patterns: list[tuple[str, str]] = [ - # BoolVar/BoolVarP - ( - r'(\w+Cmd)?\.Flags\(\)\.BoolVarP?\(&?(\w+),\s*"([^"]+)",\s*"([^"]*)",\s*(\w+),\s*"([^"]+)"', - "bool", - ), - # StringVar/StringVarP - ( - r'(\w+Cmd)?\.Flags\(\)\.StringVarP?\(&?(\w+),\s*"([^"]+)",\s*"([^"]*)",\s*"([^"]*)",\s*"([^"]+)"', - "string", - ), - # IntVar/IntVarP - ( - r'(\w+Cmd)?\.Flags\(\)\.IntVarP?\(&?(\w+),\s*"([^"]+)",\s*"([^"]*)",\s*(\d+),\s*"([^"]+)"', - "int", - ), - ] - - for pattern, flag_type in flag_patterns: - for match in re.finditer(pattern, init_body): - groups = match.groups() - if groups[0] and cmd_var not in groups[0]: - continue # Skip flags for other commands - - flag = Flag( - name=groups[2], - shorthand=groups[3] if len(groups) > 3 else "", - flag_type=flag_type, - description=str(groups[-1]) if len(groups) > 0 else "", - ) - - # Set default value based on type - if flag_type == "bool": - flag.default_value = ( - groups[4] == "true" if len(groups) > 4 else False - ) - elif flag_type == "string": - flag.default_value = groups[4] if len(groups) > 4 else "" - elif flag_type == "int": - flag.default_value = int(groups[4]) if len(groups) > 4 else 0 - - flags.append(flag) - - return flags - - def _var_to_cmd_name(self, var_name: str) -> str: - """Convert Go variable name to command name.""" - # Remove "Cmd" suffix - if var_name.endswith("Cmd"): - var_name = var_name[:-3] - - # Convert camelCase to kebab-case - result: list[str] = [] - for i, char in enumerate(var_name): - if i > 0 and char.isupper(): - result.append("-") - result.append(char.lower()) - - return "".join(result) - - def _build_command_hierarchy(self) -> dict[str, Any]: - """Build the command hierarchy from parent-child relationships.""" - hierarchy: dict[str, Any] = {"root": {"subcommands": []}} - - if self.root_command: - for sub_var in self.root_command.subcommands: - cmd_name = self._var_to_cmd_name(sub_var) - if cmd_name in self.commands: - hierarchy["root"]["subcommands"].append(cmd_name) - self.commands[cmd_name].parent = "root" - - # TODO: Parse subcommand relationships for nested commands - - return hierarchy - - def _extract_additional_metadata(self) -> dict[str, Any]: - """Extract additional metadata like REPL commands, shortcuts, etc.""" - metadata: dict[str, Any] = { - "repl_commands": [], - "shortcuts": {}, - "environment_variables": [], - "configuration_options": [], - } - - # Extract REPL-specific commands if repl.go exists - repl_file = self.cli_cmd_dir / "repl.go" - if repl_file.exists(): - _ = repl_file.read_text() # Will be used for REPL extraction - # Parse REPL-specific patterns - # TODO: Implement REPL command extraction - - return metadata - - def _gather_statistics(self) -> dict[str, int]: - """Gather statistics about the extracted commands.""" - stats = { - "total_commands": len(self.commands), - "commands_with_aliases": sum( - 1 for cmd in self.commands.values() if cmd.aliases - ), - "commands_with_flags": sum( - 1 for cmd in self.commands.values() if cmd.flags - ), - "total_flags": sum(len(cmd.flags) for cmd in self.commands.values()), - "hidden_commands": sum(1 for cmd in self.commands.values() if cmd.hidden), - "auth_required": sum( - 1 for cmd in self.commands.values() if cmd.requires_auth - ), - "project_required": sum( - 1 for cmd in self.commands.values() if cmd.requires_project - ), - "plan_required": sum( - 1 for cmd in self.commands.values() if cmd.requires_plan - ), - } - return stats - - def save_inventory( - self, output_dir: Path = Path("/app/docs/reference") - ) -> dict[str, Path]: - """Save the extracted inventory to YAML and JSON files.""" - output_dir.mkdir(parents=True, exist_ok=True) - - inventory = self.extract_all() - - # Save as YAML - yaml_file = output_dir / "cli_inventory.yaml" - with open(yaml_file, "w") as f: - yaml.dump(inventory, f, default_flow_style=False, sort_keys=False) - - # Save as JSON - json_file = output_dir / "cli_inventory.json" - with open(json_file, "w") as f: - json.dump(inventory, f, indent=2) - - return {"yaml": yaml_file, "json": json_file} - - -def main() -> dict[str, Any]: - """Main function to run the CLI inventory extraction.""" - extractor = CLIInventoryExtractor() - - print("Extracting CLI command metadata from Plandex Go codebase...") - inventory = extractor.extract_all() - - print(f"\nExtracted {inventory['statistics']['total_commands']} commands") - print(f"Commands with aliases: {inventory['statistics']['commands_with_aliases']}") - print(f"Commands with flags: {inventory['statistics']['commands_with_flags']}") - print(f"Total flags: {inventory['statistics']['total_flags']}") - - # Save the inventory - output_files = extractor.save_inventory() - print("\nInventory saved to:") - print(f" - {output_files['yaml']}") - print(f" - {output_files['json']}") - - return inventory - - -if __name__ == "__main__": - main() diff --git a/src/cleveragents/discovery/cloud_features.py b/src/cleveragents/discovery/cloud_features.py deleted file mode 100644 index bfa06c54a..000000000 --- a/src/cleveragents/discovery/cloud_features.py +++ /dev/null @@ -1,478 +0,0 @@ -""" -Cloud-only features identifier for Plandex to CleverAgents migration. -Identifies features that require removal or replacement in self-hosted deployment. -""" - -import json -from pathlib import Path -from typing import Any - -import yaml - - -class CloudFeaturesExtractor: - """Identify cloud-only or deprecated features requiring removal/replacement.""" - - def __init__(self, plandex_dir: Path | None = None): - """Initialize the cloud features extractor.""" - self.plandex_dir = plandex_dir or Path("plandex") - self.cloud_features: dict[str, dict[str, Any]] = {} - - # Define feature categories - self.feature_categories = { - "billing": "Payment processing and subscription management", - "telemetry": "Usage tracking and analytics", - "managed_auth": "Centralized authentication service", - "cloud_storage": "Cloud-based data storage", - "notifications": "Cloud notification services", - "rate_limiting": "Cloud-based rate limiting", - "team_management": "Centralized team/org management", - "api_proxying": "API key management and proxying", - } - - def extract_all(self) -> dict[str, Any]: - """Extract all cloud-only features.""" - self._scan_billing_features() - self._scan_telemetry_features() - self._scan_auth_features() - self._scan_storage_features() - self._scan_notification_features() - self._scan_team_features() - self._scan_api_proxy_features() - self._scan_deprecated_features() - - # Generate replacement strategies - replacements = self._generate_replacement_strategies() - - # Generate statistics - stats = self._generate_statistics() - - return { - "cloud_features": self.cloud_features, - "replacements": replacements, - "statistics": stats, - "categories": self.feature_categories, - } - - def _scan_billing_features(self): - """Scan for billing and payment features.""" - self.cloud_features["billing_ui"] = { - "category": "billing", - "description": "Web-based billing and subscription UI", - "action": "remove", - "go_references": [ - "app/cli/cmd/billing.go", - "app/server/handlers/billing_handlers.go", - "app/shared/billing.go", - ], - "ui_elements": [ - "Billing dashboard links", - "Subscription status display", - "Payment method prompts", - ], - "replacement": "Documentation on self-hosting costs", - "priority": "high", - "notes": "Replace with self-host cost estimation guide", - } - - self.cloud_features["usage_limits"] = { - "category": "billing", - "description": "Usage-based limits and quotas", - "action": "replace", - "go_references": [ - "app/server/middleware/usage_limits.go", - "app/shared/usage.go", - ], - "functionality": ["API call limits", "Storage quotas", "Team size limits"], - "replacement": "Configurable local limits", - "priority": "medium", - "notes": "Make limits configurable via settings", - } - - def _scan_telemetry_features(self): - """Scan for telemetry and analytics features.""" - self.cloud_features["usage_telemetry"] = { - "category": "telemetry", - "description": "Usage tracking and analytics", - "action": "replace", - "go_references": [ - "app/cli/lib/telemetry.go", - "app/server/telemetry/telemetry.go", - "app/shared/telemetry.go", - ], - "data_collected": [ - "Command usage statistics", - "Model usage metrics", - "Error tracking", - "Performance metrics", - ], - "replacement": "Opt-in local telemetry with OpenTelemetry", - "priority": "medium", - "notes": "Default to disabled, provide local dashboard option", - } - - self.cloud_features["error_reporting"] = { - "category": "telemetry", - "description": "Centralized error reporting service", - "action": "replace", - "go_references": [ - "app/cli/lib/error_reporting.go", - "app/server/errors/reporting.go", - ], - "services": [ - "Sentry integration", - "Error aggregation", - "Alert notifications", - ], - "replacement": "Local error logging with optional export", - "priority": "low", - "notes": "Use structured logging with export options", - } - - def _scan_auth_features(self): - """Scan for managed authentication features.""" - self.cloud_features["managed_auth"] = { - "category": "managed_auth", - "description": "Cloud-based authentication service", - "action": "replace", - "go_references": [ - "app/server/auth/cloud_auth.go", - "app/cli/lib/auth_cloud.go", - "app/shared/auth.go", - ], - "functionality": [ - "OAuth providers", - "SSO integration", - "Password reset emails", - "Email verification", - ], - "replacement": "Local auth with optional LDAP/SAML", - "priority": "high", - "notes": "Implement local user management with pluggable auth", - } - - self.cloud_features["api_keys_cloud"] = { - "category": "managed_auth", - "description": "Cloud-managed API keys", - "action": "replace", - "go_references": ["app/server/api/keys.go", "app/cli/cmd/api_keys.go"], - "functionality": [ - "Key generation", - "Key rotation", - "Usage tracking per key", - ], - "replacement": "Local API key management", - "priority": "medium", - "notes": "Store encrypted keys locally", - } - - def _scan_storage_features(self): - """Scan for cloud storage features.""" - self.cloud_features["cloud_backups"] = { - "category": "cloud_storage", - "description": "Automated cloud backups", - "action": "remove", - "go_references": [ - "app/server/backup/cloud_backup.go", - "app/cli/cmd/backup.go", - ], - "functionality": [ - "Automated S3 backups", - "Point-in-time recovery", - "Cross-region replication", - ], - "replacement": "Local backup documentation", - "priority": "low", - "notes": "Provide backup scripts and best practices", - } - - self.cloud_features["cdn_assets"] = { - "category": "cloud_storage", - "description": "CDN-hosted static assets", - "action": "replace", - "go_references": ["app/server/static/cdn.go", "app/shared/assets.go"], - "assets": ["Documentation images", "UI components", "Model metadata"], - "replacement": "Bundle assets in distribution", - "priority": "medium", - "notes": "Include all assets in package", - } - - def _scan_notification_features(self): - """Scan for cloud notification features.""" - self.cloud_features["email_service"] = { - "category": "notifications", - "description": "Cloud email service integration", - "action": "replace", - "go_references": [ - "app/server/email/sendgrid.go", - "app/server/email/ses.go", - "app/shared/notifications.go", - ], - "functionality": [ - "Invite emails", - "Password reset", - "Notifications", - "Reports", - ], - "replacement": "SMTP configuration with local mail server", - "priority": "high", - "notes": "Support standard SMTP with templates", - } - - self.cloud_features["push_notifications"] = { - "category": "notifications", - "description": "Mobile/desktop push notifications", - "action": "remove", - "go_references": [ - "app/server/push/push.go", - "app/cli/lib/notifications.go", - ], - "services": ["Firebase messaging", "APNS", "Web push"], - "replacement": "In-app notifications only", - "priority": "low", - "notes": "Focus on CLI/TUI notifications", - } - - def _scan_team_features(self): - """Scan for team management features.""" - self.cloud_features["org_management"] = { - "category": "team_management", - "description": "Cloud-based organization management", - "action": "replace", - "go_references": [ - "app/server/org/org_management.go", - "app/cli/cmd/org.go", - "app/shared/org.go", - ], - "functionality": [ - "Org creation", - "Member management", - "Role assignment", - "Billing per org", - ], - "replacement": "Local team management with roles", - "priority": "medium", - "notes": "Simplified local team structure", - } - - self.cloud_features["team_sync"] = { - "category": "team_management", - "description": "Real-time team state synchronization", - "action": "replace", - "go_references": ["app/server/sync/team_sync.go", "app/shared/sync.go"], - "functionality": [ - "Real-time updates", - "Presence tracking", - "Shared contexts", - ], - "replacement": "Database-based sync for multi-user mode", - "priority": "low", - "notes": "Use DB polling or websockets locally", - } - - def _scan_api_proxy_features(self): - """Scan for API proxying features.""" - self.cloud_features["api_proxy"] = { - "category": "api_proxying", - "description": "Cloud API key proxying service", - "action": "remove", - "go_references": ["app/server/proxy/api_proxy.go", "app/cli/lib/proxy.go"], - "functionality": [ - "Hide user API keys", - "Rate limit per user", - "Usage tracking", - "Cost allocation", - ], - "replacement": "Direct API usage with user keys", - "priority": "high", - "notes": "Users manage their own provider API keys", - } - - def _scan_deprecated_features(self): - """Scan for deprecated or legacy features.""" - self.cloud_features["legacy_models"] = { - "category": "deprecated", - "description": "Support for deprecated model versions", - "action": "remove", - "go_references": [ - "app/shared/deprecated_models.go", - "app/cli/lib/legacy_models.go", - ], - "models": ["GPT-3 variants", "Claude v1", "Old Codex models"], - "replacement": "Current models only", - "priority": "low", - "notes": "Remove support for EOL models", - } - - self.cloud_features["old_api_versions"] = { - "category": "deprecated", - "description": "Backward compatibility with old API versions", - "action": "remove", - "go_references": ["app/server/handlers/v1/", "app/server/handlers/v2/"], - "versions": ["API v1", "API v2", "Legacy endpoints"], - "replacement": "Single current API version", - "priority": "medium", - "notes": "CleverAgents starts fresh with v1 only", - } - - def _generate_replacement_strategies(self) -> dict[str, list[dict[str, Any]]]: - """Generate replacement strategies for cloud features.""" - strategies: dict[str, list[dict[str, Any]]] = { - "remove": [], - "replace": [], - "defer": [], - } - - for feature_id, feature in self.cloud_features.items(): - action = feature.get("action", "remove") - strategy = { - "feature": feature_id, - "description": feature["description"], - "replacement": feature.get("replacement", "None"), - "priority": feature.get("priority", "low"), - "notes": feature.get("notes", ""), - } - - if action in strategies: - strategies[action].append(strategy) - - # Sort by priority - priority_order = {"high": 0, "medium": 1, "low": 2} - for action in strategies: - strategies[action].sort(key=lambda x: priority_order.get(x["priority"], 3)) - - return strategies - - def _generate_statistics(self) -> dict[str, int | dict[str, int] | set[str]]: - """Generate statistics about cloud features.""" - stats: dict[str, Any] = { - "total_features": len(self.cloud_features), - "by_category": {}, - "by_action": {"remove": 0, "replace": 0, "defer": 0}, - "by_priority": {"high": 0, "medium": 0, "low": 0}, - "go_files_affected": set(), - "functionality_count": 0, - } - - for feature in self.cloud_features.values(): - # Count by category - category = feature.get("category", "unknown") - stats["by_category"][category] = stats["by_category"].get(category, 0) + 1 - - # Count by action - action = feature.get("action", "remove") - if action in stats["by_action"]: - stats["by_action"][action] += 1 - - # Count by priority - priority = feature.get("priority", "low") - if priority in stats["by_priority"]: - stats["by_priority"][priority] += 1 - - # Collect affected files - stats["go_files_affected"].update(feature.get("go_references", [])) - - # Count functionality items - stats["functionality_count"] += len(feature.get("functionality", [])) - - stats["go_files_affected"] = len(stats["go_files_affected"]) - - return stats - - def save_results(self, output_dir: Path) -> tuple[Path, Path]: - """Save the cloud features analysis to files.""" - output_dir.mkdir(parents=True, exist_ok=True) - - results = self.extract_all() - - # Save as JSON - json_file = output_dir / "cloud_features.json" - with open(json_file, "w") as f: - json.dump(results, f, indent=2, default=str) - - # Save as YAML - yaml_file = output_dir / "cloud_features.yaml" - with open(yaml_file, "w") as f: - yaml.dump(results, f, default_flow_style=False, sort_keys=False) - - # Generate Markdown documentation - self._generate_markdown_doc(results, output_dir) - - return json_file, yaml_file - - def _generate_markdown_doc(self, results: dict[str, Any], output_dir: Path): - """Generate markdown documentation for cloud features.""" - md_file = output_dir / "cloud_features.md" - - with open(md_file, "w") as f: - f.write("# Cloud-Only Features Analysis\n\n") - f.write( - "Features that need removal or replacement for " - "self-hosted CleverAgents.\n\n" - ) - - # Write statistics - stats = results["statistics"] - f.write("## Summary\n\n") - f.write(f"- Total cloud features identified: {stats['total_features']}\n") - f.write(f"- Features to remove: {stats['by_action']['remove']}\n") - f.write(f"- Features to replace: {stats['by_action']['replace']}\n") - f.write(f"- Go files affected: {stats['go_files_affected']}\n\n") - - # Write replacement strategies - f.write("## Replacement Strategies\n\n") - - strategies = results["replacements"] - - if strategies["remove"]: - f.write("### Features to Remove\n\n") - f.write("These features should be completely removed:\n\n") - for item in strategies["remove"]: - f.write(f"- **{item['feature']}** ({item['priority']} priority)\n") - f.write(f" - {item['description']}\n") - if item["notes"]: - f.write(f" - Notes: {item['notes']}\n") - f.write("\n") - - if strategies["replace"]: - f.write("### Features to Replace\n\n") - f.write("These features need local alternatives:\n\n") - for item in strategies["replace"]: - f.write(f"- **{item['feature']}** ({item['priority']} priority)\n") - f.write(f" - {item['description']}\n") - f.write(f" - Replacement: {item['replacement']}\n") - if item["notes"]: - f.write(f" - Notes: {item['notes']}\n") - f.write("\n") - - # Write detailed features by category - f.write("## Detailed Analysis by Category\n\n") - for category, description in results["categories"].items(): - f.write(f"### {category.replace('_', ' ').title()}\n") - f.write(f"{description}\n\n") - - # Find features in this category - category_features = [ - (feat_id, feat) - for feat_id, feat in results["cloud_features"].items() - if feat.get("category") == category - ] - - for feat_id, feature in category_features: - f.write(f"#### {feat_id.replace('_', ' ').title()}\n") - f.write(f"- **Action**: {feature['action']}\n") - f.write(f"- **Priority**: {feature.get('priority', 'low')}\n") - f.write(f"- **Description**: {feature['description']}\n") - - if feature.get("functionality"): - f.write("- **Functionality**:\n") - for func in feature["functionality"]: - f.write(f" - {func}\n") - - if feature.get("replacement"): - f.write(f"- **Replacement**: {feature['replacement']}\n") - - if feature.get("notes"): - f.write(f"- **Notes**: {feature['notes']}\n") - - f.write("\n") diff --git a/src/cleveragents/discovery/data_contracts.py b/src/cleveragents/discovery/data_contracts.py deleted file mode 100644 index dae79ed1a..000000000 --- a/src/cleveragents/discovery/data_contracts.py +++ /dev/null @@ -1,610 +0,0 @@ -"""Extract and serialize data contracts from Plandex shared Go packages.""" - -import json -import re -from pathlib import Path -from typing import Any - -from pydantic import BaseModel, ConfigDict, Field - - -class FieldDefinition(BaseModel): - """Represents a field in a Go struct.""" - - name: str - type_name: str - json_tag: str | None = None - omitempty: bool = False - is_optional: bool = False - is_array: bool = False - is_map: bool = False - comment: str | None = None - - model_config = ConfigDict(validate_assignment=True) - - -class StructDefinition(BaseModel): - """Represents a Go struct definition.""" - - name: str - fields: list[FieldDefinition] - file_path: str - line_number: int - doc_comment: str | None = None - is_exported: bool = True - - model_config = ConfigDict(validate_assignment=True) - - -class EnumDefinition(BaseModel): - """Represents a Go enum/const definition.""" - - name: str - type_name: str - values: list[str] - file_path: str - line_number: int - - model_config = ConfigDict(validate_assignment=True) - - -class TypeAlias(BaseModel): - """Represents a Go type alias.""" - - name: str - underlying_type: str - file_path: str - line_number: int - - model_config = ConfigDict(validate_assignment=True) - - -class DataContract(BaseModel): - """Complete data contract for a shared module.""" - - structs: list[StructDefinition] - enums: list[EnumDefinition] - type_aliases: list[TypeAlias] - package_name: str - imports: list[str] = Field(default_factory=list) - - model_config = ConfigDict(validate_assignment=True) - - -class DataContractExtractor: - """Extract data contracts from Plandex shared Go code.""" - - def __init__(self, plandex_dir: Path): - """Initialize the extractor. - - Args: - plandex_dir: Path to plandex directory - """ - self.plandex_dir = plandex_dir - self.shared_dir = plandex_dir / "app" / "shared" - self.contracts: dict[str, DataContract] = {} - - def extract_all(self) -> dict[str, DataContract]: - """Extract contracts from all files in shared directory. - - Returns: - Dictionary mapping module names to data contracts - """ - self.contracts = {} - - if not self.shared_dir.exists(): - raise FileNotFoundError(f"Shared directory not found: {self.shared_dir}") - - for go_file in sorted(self.shared_dir.glob("*.go")): - if go_file.name in ["go.mod", "go.sum", "tygo.yaml"]: - continue - - contract = self._extract_from_file(go_file) - if contract and ( - contract.structs or contract.enums or contract.type_aliases - ): - self.contracts[go_file.stem] = contract - - return self.contracts - - def to_serializable(self) -> dict[str, Any]: - """Return the extracted contracts in plain dictionary form.""" - output: dict[str, Any] = {} - for name, contract in self.contracts.items(): - output[name] = { - "package_name": contract.package_name, - "imports": contract.imports, - "structs": [ - self._clean_struct_dict(s.model_dump()) for s in contract.structs - ], - "enums": [e.model_dump() for e in contract.enums], - "type_aliases": [t.model_dump() for t in contract.type_aliases], - } - return output - - def _extract_from_file(self, file_path: Path) -> DataContract | None: - """Extract data contracts from a single Go file. - - Args: - file_path: Path to Go file - - Returns: - Data contract or None if no contracts found - """ - content = file_path.read_text() - lines = content.split("\n") - - package_name = self._extract_package_name(content) - imports = self._extract_imports(content) - structs = self._extract_structs(content, lines, str(file_path)) - enums = self._extract_enums(content, lines, str(file_path)) - type_aliases = self._extract_type_aliases(content, lines, str(file_path)) - - return DataContract( - structs=structs, - enums=enums, - type_aliases=type_aliases, - package_name=package_name, - imports=imports, - ) - - def _extract_package_name(self, content: str) -> str: - """Extract package name from Go source.""" - match = re.search(r"^package\s+(\w+)", content, re.MULTILINE) - return match.group(1) if match else "unknown" - - def _extract_imports(self, content: str) -> list[str]: - """Extract import statements from Go source.""" - imports: list[str] = [] - # Single imports - for match in re.finditer(r'^import\s+"([^"]+)"', content, re.MULTILINE): - imports.append(match.group(1)) - - # Grouped imports - import_block_match = re.search( - r"^import\s*\((.*?)\)", content, re.MULTILINE | re.DOTALL - ) - if import_block_match: - for line in import_block_match.group(1).split("\n"): - line = line.strip() - if line and not line.startswith("//") and '"' in line: - # Handle aliased imports - import_match = re.search(r'"([^"]+)"', line) - if import_match: - imports.append(import_match.group(1)) - - return imports - - def _extract_structs( - self, content: str, lines: list[str], file_path: str - ) -> list[StructDefinition]: - """Extract struct definitions from Go source.""" - structs: list[StructDefinition] = [] - - # Find all struct definitions - struct_pattern = re.compile(r"^type\s+(\w+)\s+struct\s*{", re.MULTILINE) - - for match in struct_pattern.finditer(content): - struct_name = match.group(1) - start_pos = match.end() - line_number = content[: match.start()].count("\n") + 1 - - # Find the closing brace - brace_count = 1 - current_pos = start_pos - while brace_count > 0 and current_pos < len(content): - if content[current_pos] == "{": - brace_count += 1 - elif content[current_pos] == "}": - brace_count -= 1 - current_pos += 1 - - struct_body = content[start_pos : current_pos - 1] - fields = self._extract_fields(struct_body) - - # Extract doc comment if present - doc_comment = self._extract_doc_comment(lines, line_number - 1) - - structs.append( - StructDefinition( - name=struct_name, - fields=fields, - file_path=file_path, - line_number=line_number, - doc_comment=doc_comment, - is_exported=struct_name[0].isupper(), - ) - ) - - return structs - - def _extract_fields(self, struct_body: str) -> list[FieldDefinition]: - """Extract fields from struct body.""" - fields: list[FieldDefinition] = [] - - # Pattern to match field definitions - field_pattern = re.compile( - r"^\s*(\w+)\s+([^\s`]+)\s*(?:`([^`]+)`)?(?:\s*//(.*))?$", re.MULTILINE - ) - - for match in field_pattern.finditer(struct_body): - field_name = match.group(1) - type_name = match.group(2) - tags = match.group(3) or "" - comment = match.group(4) or "" - - # Parse JSON tag - json_tag = None - omitempty = False - json_tag_match = re.search(r'json:"([^"]+)"', tags) - if json_tag_match: - json_parts = json_tag_match.group(1).split(",") - json_tag = json_parts[0] if json_parts[0] != "-" else None - omitempty = "omitempty" in json_parts - - # Remove the JSON tag from the raw tags so remaining comments are clean - tags = tags[: json_tag_match.start()] + tags[json_tag_match.end() :] - - if comment: - comment = re.sub(r"`json:\"[^`]*\"`", "", comment) - comment = comment.replace("`", "").strip() - comment = re.sub(r"\s+", " ", comment) - - # Detect optional (pointer types) - is_optional = type_name.startswith("*") - if is_optional: - type_name = type_name[1:] - - # Detect arrays/slices - is_array = type_name.startswith("[]") - if is_array: - type_name = type_name[2:] - - # Detect maps - is_map = type_name.startswith("map[") - - fields.append( - FieldDefinition( - name=field_name, - type_name=type_name, - json_tag=json_tag, - omitempty=omitempty, - is_optional=is_optional, - is_array=is_array, - is_map=is_map, - comment=comment.strip() if comment else None, - ) - ) - - return fields - - def _extract_enums( - self, content: str, lines: list[str], file_path: str - ) -> list[EnumDefinition]: - """Extract enum/const definitions from Go source.""" - enums: list[EnumDefinition] = [] - - # Find const blocks that look like enums - const_block_pattern = re.compile( - r"^const\s*\((.*?)\)", re.MULTILINE | re.DOTALL - ) - - for match in const_block_pattern.finditer(content): - line_number = content[: match.start()].count("\n") + 1 - block_content = match.group(1) - - # Check if this looks like an enum (has a type declaration) - type_match = re.search(r"(\w+)\s+(\w+)\s*=\s*", block_content) - if type_match: - enum_name = type_match.group(2) # The type name - values: list[str] = [] - - # Extract all values of this type - value_pattern = re.compile( - rf"(\w+)\s+{re.escape(enum_name)}\s*=", re.MULTILINE - ) - for value_match in value_pattern.finditer(block_content): - values.append(value_match.group(1)) - - if values: - enums.append( - EnumDefinition( - name=enum_name, - type_name="string", # Default assumption - values=values, - file_path=file_path, - line_number=line_number, - ) - ) - - return enums - - def _extract_type_aliases( - self, content: str, lines: list[str], file_path: str - ) -> list[TypeAlias]: - """Extract type alias definitions from Go source.""" - aliases: list[TypeAlias] = [] - - # Find type aliases (not structs) - alias_pattern = re.compile(r"^type\s+(\w+)\s+(?!struct)(\S+)", re.MULTILINE) - - for match in alias_pattern.finditer(content): - alias_name = match.group(1) - underlying_type = match.group(2) - line_number = content[: match.start()].count("\n") + 1 - - aliases.append( - TypeAlias( - name=alias_name, - underlying_type=underlying_type, - file_path=file_path, - line_number=line_number, - ) - ) - - return aliases - - def _extract_doc_comment(self, lines: list[str], line_idx: int) -> str | None: - """Extract documentation comment before a definition.""" - doc_lines: list[str] = [] - - # Look backwards for comment lines - while line_idx >= 0: - line = lines[line_idx].strip() - if line.startswith("//"): - doc_lines.insert(0, line[2:].strip()) - elif not line: - # Empty line, continue looking - pass - else: - # Non-comment, non-empty line - stop - break - line_idx -= 1 - - return "\n".join(doc_lines) if doc_lines else None - - def save_contracts(self, output_dir: Path) -> None: - """Save extracted contracts to files. - - Args: - output_dir: Directory to save contract files - """ - output_dir.mkdir(parents=True, exist_ok=True) - - # Save as JSON - json_output = output_dir / "data_contracts.json" - with open(json_output, "w") as f: - contracts_dict: dict[str, Any] = {} - for name, contract in self.contracts.items(): - contracts_dict[name] = { - "package_name": contract.package_name, - "imports": contract.imports, - "structs": [ - self._clean_struct_dict(s.model_dump()) - for s in contract.structs - ], - "enums": [e.model_dump() for e in contract.enums], - "type_aliases": [t.model_dump() for t in contract.type_aliases], - } - json.dump(contracts_dict, f, indent=2) - - # Save as YAML - try: - import yaml - - yaml_output = output_dir / "data_contracts.yaml" - with open(yaml_output, "w") as f: - yaml.dump(contracts_dict, f, default_flow_style=False, sort_keys=False) - except ImportError: - # PyYAML not installed, skip YAML output - pass - - # Generate Python dataclass stubs - self._generate_python_stubs(output_dir / "stubs") - - # Generate example fixtures - self._generate_example_fixtures(output_dir / "fixtures") - - def _generate_python_stubs(self, output_dir: Path) -> None: - """Generate Python dataclass stubs from contracts. - - Args: - output_dir: Directory to save Python stub files - """ - output_dir.mkdir(parents=True, exist_ok=True) - - for module_name, contract in self.contracts.items(): - stub_file = output_dir / f"{module_name}.py" - - with open(stub_file, "w") as f: - f.write('"""Auto-generated Python stubs from Go contracts."""\n\n') - f.write("from dataclasses import dataclass, field\n") - f.write("from typing import Any, Dict, List, Optional\n") - f.write("from datetime import datetime\n") - f.write("from enum import Enum\n\n") - - # Generate enums - for enum_def in contract.enums: - if enum_def.values: - f.write(f"\nclass {enum_def.name}(str, Enum):\n") - f.write(f' """Enum for {enum_def.name}."""\n\n') - for value in enum_def.values: - f.write(f' {value} = "{value}"\n') - f.write("\n") - - # Generate type aliases - for alias in contract.type_aliases: - python_type = self._go_type_to_python(alias.underlying_type) - f.write(f"\n{alias.name} = {python_type}\n") - - # Generate dataclasses - for struct in contract.structs: - if not struct.is_exported: - continue - - f.write("\n@dataclass\n") - f.write(f"class {struct.name}:\n") - - if struct.doc_comment: - f.write(f' """{struct.doc_comment}"""\n\n') - else: - f.write(f' """Data contract for {struct.name}."""\n\n') - - if not struct.fields: - f.write(" pass\n") - else: - for field_def in struct.fields: - python_type = self._field_to_python_type(field_def) - field_name = field_def.json_tag or field_def.name.lower() - - # Handle reserved Python keywords - if field_name in ["class", "type", "from", "import"]: - field_name = field_name + "_" - - if field_def.comment: - f.write(f" # {field_def.comment}\n") - - if field_def.is_optional or field_def.omitempty: - f.write(f" {field_name}: {python_type} = None\n") - elif field_def.is_array: - f.write( - f" {field_name}: {python_type} = " - "field(default_factory=list)\n" - ) - elif field_def.is_map: - f.write( - f" {field_name}: {python_type} = " - "field(default_factory=dict)\n" - ) - else: - f.write(f" {field_name}: {python_type}\n") - - def _field_to_python_type(self, field: FieldDefinition) -> str: - """Convert Go field type to Python type hint.""" - base_type = self._go_type_to_python(field.type_name) - - if field.is_array: - base_type = f"List[{base_type}]" - elif field.is_map: - # Simplified - assumes string keys - base_type = f"Dict[str, {base_type}]" - - if field.is_optional: - base_type = f"Optional[{base_type}]" - - return base_type - - def _go_type_to_python(self, go_type: str) -> str: - """Convert Go type to Python type hint.""" - type_mapping = { - "string": "str", - "int": "int", - "int8": "int", - "int16": "int", - "int32": "int", - "int64": "int", - "uint": "int", - "uint8": "int", - "uint16": "int", - "uint32": "int", - "uint64": "int", - "float32": "float", - "float64": "float", - "bool": "bool", - "byte": "bytes", - "rune": "str", - "interface{}": "Any", - "any": "Any", - "time.Time": "datetime", - "error": "Optional[str]", - } - - # Remove package prefixes - if "." in go_type: - go_type = go_type.split(".")[-1] - - return type_mapping.get(go_type, go_type) - - def _generate_example_fixtures(self, output_dir: Path) -> None: - """Generate example JSON fixtures for each contract. - - Args: - output_dir: Directory to save fixture files - """ - output_dir.mkdir(parents=True, exist_ok=True) - - for module_name, contract in self.contracts.items(): - for struct in contract.structs: - if not struct.is_exported: - continue - - fixture_file = ( - output_dir / f"{module_name}_{struct.name.lower()}_example.json" - ) - fixture = self._generate_example_data(struct) - - with open(fixture_file, "w") as f: - json.dump(fixture, f, indent=2) - - def _generate_example_data(self, struct: StructDefinition) -> dict[str, Any]: - """Generate example data for a struct.""" - example: dict[str, Any] = {} - - for field in struct.fields: - field_name = field.json_tag or field.name.lower() - - if field.omitempty and field.is_optional: - # Skip optional fields for minimal example - continue - - if field.is_array: - example[field_name] = [self._example_value_for_type(field.type_name)] - elif field.is_map: - example[field_name] = { - "key": self._example_value_for_type(field.type_name) - } - else: - example[field_name] = self._example_value_for_type(field.type_name) - - return example - - def _example_value_for_type(self, type_name: str) -> Any: - """Generate example value for a type.""" - examples: dict[str, Any] = { - "string": "example_string", - "int": 42, - "int32": 42, - "int64": 42, - "float32": 3.14, - "float64": 3.14159, - "bool": True, - "time.Time": "2024-01-01T00:00:00Z", - } - - return examples.get(type_name, f"<{type_name}>") - - def _clean_struct_dict(self, struct_dict: dict[str, Any]) -> dict[str, Any]: - """Clean up struct dictionary for JSON serialization.""" - # Remove None values and clean up field dictionaries - if "fields" in struct_dict: - struct_dict["fields"] = [ - {k: v for k, v in field.items() if v is not None} - for field in struct_dict["fields"] - ] - return {k: v for k, v in struct_dict.items() if v is not None} - - -if __name__ == "__main__": - import argparse - - parser = argparse.ArgumentParser(description="Extract data contracts from Plandex") - parser.add_argument("plandex_dir", help="Path to Plandex repository") - parser.add_argument("--output", default="docs/reference", help="Output directory") - - args = parser.parse_args() - - extractor = DataContractExtractor(args.plandex_dir) - extractor.extract_all() - extractor.save_contracts(args.output) - - print("Data contract extraction complete") diff --git a/src/cleveragents/discovery/env_variables.py b/src/cleveragents/discovery/env_variables.py deleted file mode 100644 index 8cfc25910..000000000 --- a/src/cleveragents/discovery/env_variables.py +++ /dev/null @@ -1,354 +0,0 @@ -"""Extract environment variables from Plandex Go source code and documentation.""" - -from __future__ import annotations - -import json -import re -from pathlib import Path -from typing import Any - -import yaml - - -class EnvironmentVariableExtractor: - """Extract environment variables from Go code and documentation.""" - - def __init__(self, plandex_root: str | Path): - """Initialize the extractor with Plandex root directory.""" - self.plandex_root = Path(plandex_root) - self.variables: dict[str, dict[str, Any]] = {} - - def extract_from_documentation(self) -> None: - """Extract environment variables from documentation files.""" - doc_file = self.plandex_root / "docs" / "docs" / "environment-variables.md" - if not doc_file.exists(): - return - - with doc_file.open("r", encoding="utf-8") as f: - content = f.read() - - # Pattern to match environment variable documentation - # Matches lines like: VARIABLE_NAME= # Description - pattern = r"^([A-Z_]+[A-Z0-9_]*)=([^#]*)?#?\s*(.*)$" - - current_section = "General" - for line in content.splitlines(): - # Track sections - if line.startswith("###") or line.startswith("##"): - current_section = line.strip("#").strip() - - match = re.match(pattern, line.strip()) - if match: - var_name = match.group(1) - default_value = match.group(2).strip() if match.group(2) else "" - description = match.group(3).strip() if match.group(3) else "" - - # Clean up default value - if default_value and not default_value.isspace(): - # Remove quotes if present - default_value = default_value.strip("'\"") - else: - default_value = "" - - if var_name not in self.variables: - self.variables[var_name] = { - "name": var_name, - "default": default_value, - "description": description, - "category": current_section, - "sources": ["documentation"], - "usage_locations": [], - "proposed_cleveragents_name": self._propose_new_name(var_name), - } - - def extract_from_go_source(self) -> None: - """Extract environment variable usage from Go source files.""" - # Common patterns for environment variable access in Go - patterns = [ - r'os\.Getenv\("([^"]+)"\)', - r'os\.LookupEnv\("([^"]+)"\)', - r'viper\.GetString\("([^"]+)"\)', - r'viper\.GetBool\("([^"]+)"\)', - r'viper\.GetInt\("([^"]+)"\)', - ] - - # Search through Go files - for go_file in self.plandex_root.rglob("*.go"): - # Skip vendor and test files - if "vendor" in go_file.parts or "_test.go" in str(go_file): - continue - - try: - with go_file.open("r", encoding="utf-8") as f: - content = f.read() - - for pattern in patterns: - matches = re.finditer(pattern, content) - for match in matches: - var_name = match.group(1) - - # Get context around the match for default value detection - line_start = content.rfind("\n", 0, match.start()) + 1 - line_end = content.find("\n", match.end()) - if line_end == -1: - line_end = len(content) - line = content[line_start:line_end] - - # Try to detect default values - default = self._extract_default_value(line, var_name) - - # Get line number for reference - line_num = content[: match.start()].count("\n") + 1 - relative_path = go_file.relative_to(self.plandex_root) - location = f"{relative_path}:{line_num}" - - if var_name not in self.variables: - self.variables[var_name] = { - "name": var_name, - "default": default, - "description": "", - "category": self._categorize_by_path(go_file), - "sources": ["code"], - "usage_locations": [location], - "proposed_cleveragents_name": self._propose_new_name( - var_name - ), - } - else: - if "code" not in self.variables[var_name]["sources"]: - self.variables[var_name]["sources"].append("code") - if ( - location - not in self.variables[var_name]["usage_locations"] - ): - self.variables[var_name]["usage_locations"].append( - location - ) - # Update default if we found one and didn't have it - if default and not self.variables[var_name]["default"]: - self.variables[var_name]["default"] = default - - except (OSError, UnicodeDecodeError): - continue - - def _extract_default_value(self, line: str, var_name: str) -> str: - """Try to extract default value from a line of Go code.""" - # Pattern for default value assignments - # e.g., if val == "" { val = "default" } - patterns = [ - r'if\s+\w+\s*==\s*""\s*{\s*\w+\s*=\s*"([^"]+)"', - r'Default\s*:\s*"([^"]+)"', - r'defaultValue\s*:=\s*"([^"]+)"', - ] - - for pattern in patterns: - match = re.search(pattern, line) - if match: - return match.group(1) - - return "" - - def _categorize_by_path(self, file_path: Path) -> str: - """Categorize variable by file path.""" - path_str = str(file_path) - - if "cli" in path_str: - return "CLI" - elif "server" in path_str: - return "Server" - elif "shared" in path_str: - return "Shared" - elif "model" in path_str or "ai" in path_str: - return "LLM Providers" - else: - return "General" - - def _propose_new_name(self, var_name: str) -> str: - """Propose CleverAgents naming convention for environment variable.""" - # Replace PLANDEX with CLEVERAGENTS - if var_name.startswith("PLANDEX_"): - return var_name.replace("PLANDEX_", "CLEVERAGENTS_") - - # Keep provider-specific names as-is - provider_prefixes = [ - "OPENAI_", - "ANTHROPIC_", - "GEMINI_", - "AZURE_", - "AWS_", - "OPENROUTER_", - "GOOGLE_", - "VERTEXAI_", - "DEEPSEEK_", - "PERPLEXITY_", - ] - for prefix in provider_prefixes: - if var_name.startswith(prefix): - return var_name - - # Add CLEVERAGENTS prefix for generic names - if not var_name.startswith("CLEVERAGENTS_"): - return f"CLEVERAGENTS_{var_name}" - - return var_name - - def identify_conflicts(self) -> list[dict[str, Any]]: - """Identify conflicting or deprecated variables.""" - conflicts: list[dict[str, Any]] = [] - - for var_name, var_info in self.variables.items(): - # Check for variables that need migration - if var_name.startswith("PLANDEX_"): - conflicts.append( - { - "old_name": var_name, - "new_name": var_info["proposed_cleveragents_name"], - "type": "migration_required", - "description": "Rename from Plandex to CleverAgents namespace", - } - ) - - # Check for potentially deprecated variables - if ( - "development" in var_info.get("description", "").lower() - and "PLANDEX_DEV" in var_name - ): - conflicts.append( - { - "old_name": var_name, - "new_name": var_info["proposed_cleveragents_name"], - "type": "development_only", - "description": ( - "Development-specific variable, may need reconsideration" - ), - } - ) - - return conflicts - - def generate_mapping_table(self) -> dict[str, str]: - """Generate a simple mapping table from old to new names.""" - mapping: dict[str, str] = {} - for var_name, var_info in self.variables.items(): - if var_name != var_info["proposed_cleveragents_name"]: - mapping[var_name] = var_info["proposed_cleveragents_name"] - return mapping - - def extract_all(self) -> dict[str, Any]: - """Extract environment variables from all sources.""" - self.extract_from_documentation() - self.extract_from_go_source() - - # Sort variables by category and name - sorted_vars = dict( - sorted(self.variables.items(), key=lambda x: (x[1]["category"], x[0])) - ) - - return { - "variables": sorted_vars, - "conflicts": self.identify_conflicts(), - "mapping": self.generate_mapping_table(), - "statistics": { - "total_variables": len(self.variables), - "documented_variables": sum( - 1 - for v in self.variables.values() - if "documentation" in v["sources"] - ), - "code_only_variables": sum( - 1 - for v in self.variables.values() - if "code" in v["sources"] and "documentation" not in v["sources"] - ), - "migration_required": sum( - 1 for v in self.variables if v.startswith("PLANDEX_") - ), - }, - } - - def save_results(self, output_dir: str | Path) -> None: - """Save extraction results to files.""" - output_dir = Path(output_dir) - output_dir.mkdir(parents=True, exist_ok=True) - - results = self.extract_all() - - # Save as JSON - json_file = output_dir / "env_variables.json" - with json_file.open("w", encoding="utf-8") as f: - json.dump(results, f, indent=2, default=str) - - # Save as YAML - yaml_file = output_dir / "env_variables.yaml" - with yaml_file.open("w", encoding="utf-8") as f: - yaml.dump(results, f, default_flow_style=False, sort_keys=False) - - # Save mapping table as simple text - mapping_file = output_dir / "env_mapping.txt" - with mapping_file.open("w", encoding="utf-8") as f: - f.write("# Environment Variable Mapping\n") - f.write("# Old Name -> New Name\n") - f.write("#" + "=" * 50 + "\n\n") - for old, new in results["mapping"].items(): - f.write(f"{old} -> {new}\n") - - # Generate migration guide - migration_file = output_dir / "env_migration_guide.md" - with migration_file.open("w", encoding="utf-8") as f: - f.write("# Environment Variable Migration Guide\n\n") - f.write("## Overview\n\n") - f.write(f"Total variables: {results['statistics']['total_variables']}\n") - f.write( - f"Variables requiring migration: " - f"{results['statistics']['migration_required']}\n" - ) - f.write( - f"Documented variables: " - f"{results['statistics']['documented_variables']}\n" - ) - f.write( - f"Code-only variables: " - f"{results['statistics']['code_only_variables']}\n\n" - ) - - f.write("## Variable Mappings\n\n") - f.write("| Old Name | New Name | Category | Default | Description |\n") - f.write("|----------|----------|----------|---------|-------------|\n") - - for var_name, var_info in results["variables"].items(): - old = var_name - new = var_info["proposed_cleveragents_name"] - category = var_info["category"] - default = var_info["default"] or "(none)" - desc = ( - var_info["description"][:50] + "..." - if len(var_info["description"]) > 50 - else var_info["description"] - ) - f.write(f"| {old} | {new} | {category} | {default} | {desc} |\n") - - f.write("\n## Conflicts and Warnings\n\n") - for conflict in results["conflicts"]: - f.write(f"- **{conflict['old_name']}**: {conflict['description']}\n") - f.write(f" - Type: {conflict['type']}\n") - f.write(f" - Suggested: {conflict['new_name']}\n\n") - - print("Environment variable extraction complete:") - print(f" - Found {results['statistics']['total_variables']} variables") - print(f" - Saved to {output_dir}/") - - -if __name__ == "__main__": - import argparse - - parser = argparse.ArgumentParser( - description="Extract environment variables from Plandex" - ) - parser.add_argument("plandex_dir", help="Path to Plandex repository") - parser.add_argument("--output", default="docs/reference", help="Output directory") - - args = parser.parse_args() - - extractor = EnvironmentVariableExtractor(args.plandex_dir) - extractor.save_results(args.output) - print("Environment variable extraction complete") diff --git a/src/cleveragents/discovery/implicit_behaviors.py b/src/cleveragents/discovery/implicit_behaviors.py deleted file mode 100644 index f4b51916c..000000000 --- a/src/cleveragents/discovery/implicit_behaviors.py +++ /dev/null @@ -1,479 +0,0 @@ -""" -Extract implicit runtime behaviors from Plandex Go code. - -This module analyzes the Plandex Go codebase to identify implicit behaviors -such as auto-context loading, git locking, model sync retries, and other -patterns that must be replicated in the Python implementation. -""" - -import json -import os -import re -from pathlib import Path -from typing import Any - -import yaml -from pydantic import BaseModel, ConfigDict, Field - - -class BehaviorPattern(BaseModel): - """Represents an implicit behavior pattern found in the code.""" - - name: str - category: str - description: str - locations: list[str] = Field(default_factory=list) - triggers: list[str] = Field(default_factory=list) - timing: str | None = None - concurrency: str | None = None - failure_handling: str | None = None - python_considerations: list[str] = Field(default_factory=list) - - model_config = ConfigDict(validate_assignment=True) - - -class ImplicitBehaviorExtractor: - """Extract implicit runtime behaviors from Plandex Go codebase.""" - - def __init__(self, plandex_root: str | Path): - """Initialize extractor with Plandex repository root.""" - self.plandex_root = Path(plandex_root) - self.behaviors: list[BehaviorPattern] = [] - - def extract_all(self) -> dict[str, Any]: - """Extract all implicit behaviors from the codebase.""" - self.behaviors = [] - - # Analyze different categories of behaviors - self._extract_auto_context_behaviors() - self._extract_locking_behaviors() - self._extract_retry_behaviors() - self._extract_validation_behaviors() - self._extract_goroutine_patterns() - self._extract_streaming_behaviors() - self._extract_telemetry_behaviors() - - return self._generate_report() - - def _extract_auto_context_behaviors(self): - """Extract auto-context loading heuristics.""" - # Search in the entire cli directory, not just lib - cli_dir = self.plandex_root / "app" / "cli" - - patterns = [ - (r"AutoLoadContext", "Auto-load context configuration"), - (r"loadContextFromFile", "Load context from file patterns"), - (r"contextLoader\.Load", "Context loader usage"), - (r"@\w+", "At-symbol context references"), - (r"contextDefaults", "Default context patterns"), - ] - - for pattern, desc in patterns: - matches = self._search_pattern(cli_dir, pattern) - if matches: - behavior = BehaviorPattern( - name=f"Auto-Context: {desc}", - category="auto-context", - description=f"Automatic context loading based on {desc.lower()}", - # Limit examples to first 10 matches - locations=[f"{f}:{line}" for f, line in matches[:10]], - triggers=["CLI command execution", "@ symbol in input"], - python_considerations=[ - "Use Python decorators for auto-loading", - "Consider asyncio for concurrent context loads", - ], - ) - self.behaviors.append(behavior) - - def _extract_locking_behaviors(self): - """Extract git and resource locking patterns.""" - server_db = self.plandex_root / "app" / "server" / "db" - cli_lib = self.plandex_root / "app" / "cli" / "lib" - - patterns = [ - (r"Lock\s*\(\)", "Explicit lock acquisition"), - (r"Unlock\s*\(\)", "Lock release"), - (r"sync\.Mutex", "Mutex usage"), - (r"sync\.RWMutex", "Read-write mutex"), - (r"lockFile", "File-based locking"), - (r"gitLock", "Git-specific locking"), - (r"defer\s+.*Unlock", "Deferred unlock patterns"), - ] - - for pattern, desc in patterns: - matches: list[tuple[str, int]] = [] - matches.extend(self._search_pattern(server_db, pattern)) - matches.extend(self._search_pattern(cli_lib, pattern)) - - if matches: - behavior = BehaviorPattern( - name=f"Locking: {desc}", - category="locking", - description=f"Resource locking via {desc.lower()}", - locations=[f"{f}:{line}" for f, line in matches], - concurrency="Go mutexes/file locks", - failure_handling="Deferred unlock ensures cleanup", - python_considerations=[ - "Use threading.Lock or asyncio.Lock", - "Consider fcntl for file locks", - "Use context managers for automatic cleanup", - ], - ) - self.behaviors.append(behavior) - - def _extract_retry_behaviors(self): - """Extract retry and backoff patterns.""" - patterns = [ - (r"retry\.\w+", "Retry library usage"), - (r"for\s+attempts?\s*:=.*{", "Manual retry loops"), - (r"time\.Sleep\(.*\*\s*time\.", "Exponential backoff"), - (r"backoff", "Backoff patterns"), - (r"maxRetries", "Max retry configuration"), - (r"retryDelay", "Retry delay configuration"), - ] - - all_matches: list[tuple[str, str, list[tuple[str, int]]]] = [] - for root, _dirs, files in os.walk(self.plandex_root / "app"): - for file in files: - if file.endswith(".go"): - file_path = Path(root) / file - for pattern, desc in patterns: - matches = self._search_pattern(file_path.parent, pattern, file) - if matches: - all_matches.append((pattern, desc, matches)) - - for _pattern, desc, matches in all_matches: - behavior = BehaviorPattern( - name=f"Retry: {desc}", - category="retry", - description=f"Retry logic using {desc.lower()}", - locations=[f"{f}:{ln}" for f, ln in matches], - timing="Exponential backoff common", - failure_handling="Max attempts then fail", - python_considerations=[ - "Use tenacity or backoff libraries", - "Consider asyncio.wait_for for timeouts", - "Implement circuit breaker pattern", - ], - ) - self.behaviors.append(behavior) - - def _extract_validation_behaviors(self): - """Extract input validation and sanitization patterns.""" - patterns = [ - (r"validate\w+", "Validation functions"), - (r"sanitize\w+", "Sanitization functions"), - (r'if\s+.*==\s*""', "Empty string checks"), - (r"strings\.TrimSpace", "String trimming"), - (r"regexp\.MustCompile", "Regex validation"), - (r'errors\.New\("invalid', "Validation errors"), - ] - - for pattern, desc in patterns: - matches: list[tuple[str, int]] = [] - for root, _dirs, files in os.walk(self.plandex_root / "app"): - for file in files: - if file.endswith(".go"): - file_path = Path(root) / file - file_matches = self._search_pattern( - file_path.parent, pattern, file - ) - matches.extend(file_matches) - - if matches: - behavior = BehaviorPattern( - name=f"Validation: {desc}", - category="validation", - description=f"Input validation via {desc.lower()}", - locations=[ - f"{f}:{ln}" for f, ln in matches[:10] - ], # Limit to 10 examples - triggers=["User input", "API requests"], - python_considerations=[ - "Use pydantic for data validation", - "Consider marshmallow for serialization", - "Apply validators as decorators", - ], - ) - self.behaviors.append(behavior) - - def _extract_goroutine_patterns(self): - """Extract goroutine and concurrency patterns.""" - patterns = [ - (r"go\s+func\s*\(", "Anonymous goroutines"), - (r"go\s+\w+\(", "Named goroutine calls"), - (r"chan\s+\w+", "Channel declarations"), - (r"select\s*{", "Select statements"), - (r"<-\w+", "Channel receive"), - (r"\w+\s*<-", "Channel send"), - (r"sync\.WaitGroup", "WaitGroup usage"), - ] - - for pattern, desc in patterns: - matches: list[tuple[str, int]] = [] - for root, _dirs, files in os.walk(self.plandex_root / "app"): - for file in files: - if file.endswith(".go"): - file_path = Path(root) / file - file_matches = self._search_pattern( - file_path.parent, pattern, file - ) - matches.extend(file_matches) - - if matches: - behavior = BehaviorPattern( - name=f"Concurrency: {desc}", - category="concurrency", - description=f"Concurrent execution via {desc.lower()}", - # Limit examples to first 10 - locations=[f"{f}:{ln}" for f, ln in matches[:10]], - concurrency=f"Go {desc.lower()}", - python_considerations=[ - "Use asyncio tasks for coroutines", - "Queue.Queue for channel-like behavior", - "asyncio.gather for WaitGroup equivalent", - "Consider threading for CPU-bound tasks", - ], - ) - self.behaviors.append(behavior) - - def _extract_streaming_behaviors(self): - """Extract streaming and real-time update patterns.""" - patterns = [ - (r"stream\.\w+", "Stream operations"), - (r"websocket", "WebSocket usage"), - (r"SSE|ServerSentEvents", "Server-sent events"), - (r"io\.Copy", "Stream copying"), - (r"bufio\.", "Buffered I/O"), - (r"Flush\(\)", "Stream flushing"), - ] - - for pattern, desc in patterns: - matches: list[tuple[str, int]] = [] - for root, _dirs, files in os.walk(self.plandex_root / "app"): - for file in files: - if file.endswith(".go"): - file_path = Path(root) / file - file_matches = self._search_pattern( - file_path.parent, pattern, file - ) - matches.extend(file_matches) - - if matches: - behavior = BehaviorPattern( - name=f"Streaming: {desc}", - category="streaming", - description=f"Real-time data streaming via {desc.lower()}", - locations=[f"{f}:{ln}" for f, ln in matches[:10]], - timing="Real-time/low-latency", - python_considerations=[ - "Use aiohttp for WebSocket support", - "Consider Server-Sent Events for unidirectional", - "Implement proper backpressure handling", - "Use async generators for streaming", - ], - ) - self.behaviors.append(behavior) - - def _extract_telemetry_behaviors(self): - """Extract telemetry and metrics collection patterns.""" - patterns = [ - (r"telemetry\.\w+", "Telemetry calls"), - (r"metrics\.\w+", "Metrics collection"), - (r"track\w+", "Tracking functions"), - (r"analytics", "Analytics usage"), - (r"usage\.\w+", "Usage tracking"), - (r"CLEVERAGENTS_DISABLE_TELEMETRY", "Telemetry opt-out"), - ] - - for pattern, desc in patterns: - matches: list[tuple[str, int]] = [] - for root, _dirs, files in os.walk(self.plandex_root / "app"): - for file in files: - if file.endswith(".go"): - file_path = Path(root) / file - file_matches = self._search_pattern( - file_path.parent, pattern, file - ) - matches.extend(file_matches) - - if matches: - behavior = BehaviorPattern( - name=f"Telemetry: {desc}", - category="telemetry", - description=f"Usage tracking via {desc.lower()}", - locations=[f"{f}:{ln}" for f, ln in matches[:10]], - triggers=["Command execution", "Feature usage"], - python_considerations=[ - "Make telemetry opt-in by default", - "Use structured logging for metrics", - "Consider OpenTelemetry for standards", - "Respect privacy settings strictly", - ], - ) - self.behaviors.append(behavior) - - def _search_pattern( - self, directory: Path, pattern: str, filename: str | None = None - ) -> list[tuple[str, int]]: - """Search for a pattern in Go files.""" - matches: list[tuple[str, int]] = [] - - if not directory.exists(): - return matches - - if filename: - files = [directory / filename] if (directory / filename).exists() else [] - else: - files = list(directory.rglob("*.go")) - - for file_path in files: - try: - with open(file_path, encoding="utf-8") as f: - for line_no, line in enumerate(f, 1): - if re.search(pattern, line, re.IGNORECASE): - rel_path = file_path.relative_to(self.plandex_root) - matches.append((str(rel_path), line_no)) - except Exception: - continue - - return matches - - def _generate_report(self) -> dict[str, Any]: - """Generate comprehensive behavior report.""" - # Group behaviors by category - by_category: dict[str, list[BehaviorPattern]] = {} - for behavior in self.behaviors: - if behavior.category not in by_category: - by_category[behavior.category] = [] - by_category[behavior.category].append(behavior) - - # Generate summary statistics - stats = { - "total_behaviors": len(self.behaviors), - "categories": list(by_category.keys()), - "behaviors_per_category": { - cat: len(behaviors) for cat, behaviors in by_category.items() - }, - "python_migration_considerations": self._collect_migration_notes(), - } - - return { - "behaviors": [b.model_dump() for b in self.behaviors], - "by_category": { - cat: [b.model_dump() for b in behaviors] - for cat, behaviors in by_category.items() - }, - "statistics": stats, - "sequence_diagrams": self._generate_sequence_diagrams(), - } - - def _collect_migration_notes(self) -> list[str]: - """Collect unique Python migration considerations.""" - notes: set[str] = set() - for behavior in self.behaviors: - for note in behavior.python_considerations: - notes.add(note) - return sorted(list(notes)) - - def _generate_sequence_diagrams(self) -> dict[str, str]: - """Generate simplified sequence diagrams for key behaviors.""" - diagrams: dict[str, str] = {} - - # Auto-context loading sequence - diagrams["auto_context_loading"] = """ -User -> CLI: Execute command with @context -CLI -> ContextLoader: Parse @ reference -ContextLoader -> FileSystem: Load context file -FileSystem -> ContextLoader: Return content -ContextLoader -> CLI: Inject context -CLI -> Server: Execute with context -""".strip() - - # Retry with backoff sequence - diagrams["retry_with_backoff"] = """ -Client -> Service: Make request -Service -> Provider: Call API -Provider -> Service: Error/Timeout -Service -> Service: Wait (exponential backoff) -Service -> Provider: Retry request -Provider -> Service: Success -Service -> Client: Return result -""".strip() - - # Git locking sequence - diagrams["git_locking"] = """ -CLI -> LockManager: Acquire git lock -LockManager -> FileSystem: Create lock file -FileSystem -> LockManager: Lock acquired -LockManager -> CLI: Proceed -CLI -> Git: Execute operations -Git -> CLI: Complete -CLI -> LockManager: Release lock -LockManager -> FileSystem: Remove lock file -""".strip() - - return diagrams - - def save_results(self, output_dir: str | Path) -> dict[str, Any]: - """Save extraction results to files.""" - output_path = Path(output_dir) - output_path.mkdir(parents=True, exist_ok=True) - - results = self.extract_all() - - # Save as JSON - with open(output_path / "implicit_behaviors.json", "w") as f: - json.dump(results, f, indent=2) - - # Save as YAML - with open(output_path / "implicit_behaviors.yaml", "w") as f: - yaml.dump(results, f, default_flow_style=False, sort_keys=False) - - # Save documentation - with open(output_path / "implicit_behaviors.md", "w") as f: - f.write("# Implicit Behaviors in Plandex\n\n") - f.write("## Summary\n\n") - stats = results["statistics"] - f.write(f"- Total behaviors identified: {stats['total_behaviors']}\n") - f.write(f"- Categories: {', '.join(stats['categories'])}\n\n") - - f.write("## Behaviors by Category\n\n") - for category, behaviors in results["by_category"].items(): - f.write(f"### {category.title()}\n\n") - for behavior in behaviors: - f.write(f"#### {behavior['name']}\n") - f.write(f"- **Description**: {behavior['description']}\n") - if behavior.get("triggers"): - f.write(f"- **Triggers**: {', '.join(behavior['triggers'])}\n") - if behavior.get("timing"): - f.write(f"- **Timing**: {behavior['timing']}\n") - if behavior.get("concurrency"): - f.write(f"- **Concurrency**: {behavior['concurrency']}\n") - if behavior.get("failure_handling"): - f.write( - f"- **Failure Handling**: {behavior['failure_handling']}\n" - ) - if behavior.get("locations"): - locs = ", ".join(behavior["locations"][:3]) - f.write(f"- **Example Locations**: {locs}\n") - if behavior.get("python_considerations"): - f.write("- **Python Migration Notes**:\n") - for note in behavior["python_considerations"]: - f.write(f" - {note}\n") - f.write("\n") - - f.write("## Sequence Diagrams\n\n") - for name, diagram in results["sequence_diagrams"].items(): - f.write(f"### {name.replace('_', ' ').title()}\n") - f.write("```mermaid\nsequenceDiagram\n") - for line in diagram.strip().split("\n"): - if "->" in line: - f.write(f" {line.strip()}\n") - f.write("```\n\n") - - f.write("## Python Migration Considerations\n\n") - for note in stats["python_migration_considerations"]: - f.write(f"- {note}\n") - - return results diff --git a/src/cleveragents/discovery/run_all.py b/src/cleveragents/discovery/run_all.py deleted file mode 100755 index 0abe7f252..000000000 --- a/src/cleveragents/discovery/run_all.py +++ /dev/null @@ -1,218 +0,0 @@ -#!/usr/bin/env python3 -""" -Main script to run all discovery tools for the Plandex to CleverAgents migration. -This orchestrates extraction of CLI, server, data contracts, and other metadata. -""" - -import sys -from pathlib import Path - -# Add src to path for imports -sys.path.insert(0, str(Path(__file__).parent.parent)) - -from cleveragents.discovery.cli_inventory import CLIInventoryExtractor -from cleveragents.discovery.cloud_features import CloudFeaturesExtractor -from cleveragents.discovery.data_contracts import DataContractExtractor -from cleveragents.discovery.env_variables import EnvironmentVariableExtractor -from cleveragents.discovery.implicit_behaviors import ImplicitBehaviorExtractor -from cleveragents.discovery.server_endpoints import ServerEndpointExtractor -from cleveragents.discovery.shell_assets import ShellAssetExtractor -from cleveragents.discovery.workflow_parity import WorkflowParityExtractor - - -def main() -> None: - """Run all discovery tools and generate artifacts.""" - - print("=" * 70) - print("CleverAgents Discovery Tool Suite") - print("Extracting metadata from Plandex Go codebase") - print("=" * 70) - - # 1. Extract CLI inventory - print("\n1. Extracting CLI Command Inventory...") - print("-" * 40) - cli_extractor = CLIInventoryExtractor() - cli_inventory = cli_extractor.extract_all() - output_files = cli_extractor.save_inventory() - - print(f"✓ Extracted {cli_inventory['statistics']['total_commands']} commands") - print( - " - Commands with aliases: " - f"{cli_inventory['statistics']['commands_with_aliases']}" - ) - print( - f" - Commands with flags: {cli_inventory['statistics']['commands_with_flags']}" - ) - print(f" - Total flags: {cli_inventory['statistics']['total_flags']}") - print(f" - Hidden commands: {cli_inventory['statistics']['hidden_commands']}") - print(f" - Auth required: {cli_inventory['statistics']['auth_required']}") - print(f" - Project required: {cli_inventory['statistics']['project_required']}") - print(f" - Plan required: {cli_inventory['statistics']['plan_required']}") - print("\n Output files:") - print(f" - {output_files['yaml']}") - print(f" - {output_files['json']}") - - # 2. Extract server endpoints - print("\n2. Extracting Server Endpoints...") - print("-" * 40) - server_extractor = ServerEndpointExtractor() - server_inventory = server_extractor.extract_endpoints() - yaml_path, json_path = server_extractor.save_inventory() - - print(f"✓ Extracted {server_inventory['statistics']['total_endpoints']} endpoints") - streaming = server_inventory["statistics"]["streaming_endpoints"] - print(f" - Streaming endpoints: {streaming}") - print(f" - Categories: {server_inventory['statistics']['categories']}") - print(f" - Methods: {server_inventory['statistics']['methods']}") - print("\n Output files:") - print(f" - {yaml_path}") - print(f" - {json_path}") - print(" - docs/reference/server_api.yaml (OpenAPI spec)") - - # 3. Extract data contracts - print("\n3. Extracting Shared Data Contracts...") - print("-" * 40) - from pathlib import Path - - plandex_dir = Path(__file__).parent.parent.parent.parent / "plandex" - contract_extractor = DataContractExtractor(plandex_dir) - contracts = contract_extractor.extract_all() - output_dir = Path("docs/reference/contracts") - contract_extractor.save_contracts(output_dir) - - # Count statistics - total_structs = sum(len(c.structs) for c in contracts.values()) - total_enums = sum(len(c.enums) for c in contracts.values()) - total_aliases = sum(len(c.type_aliases) for c in contracts.values()) - - print(f"✓ Extracted contracts from {len(contracts)} modules") - print(f" - Structs: {total_structs}") - print(f" - Enums: {total_enums}") - print(f" - Type aliases: {total_aliases}") - print("\n Output files:") - print(f" - {output_dir}/data_contracts.json") - print(f" - {output_dir}/data_contracts.yaml") - print(f" - {output_dir}/stubs/ (Python dataclass stubs)") - print(f" - {output_dir}/fixtures/ (Example JSON fixtures)") - - # 4. Extract shell assets - print("\n4. Extracting Shell Assets...") - print("-" * 40) - shell_extractor = ShellAssetExtractor() - shell_catalog = shell_extractor.extract_all() - shell_extractor.save_catalog() - - stats = shell_catalog["statistics"] - print(f"✓ Extracted {stats['total_scripts']} shell scripts") - print(f" - Scripts requiring Docker: {stats['docker_required']}") - print(f" - Scripts requiring Git: {stats['git_required']}") - print(f" - Idempotent scripts: {stats['idempotent']}") - print(f" - Suggested for Python replacement: {stats['python_replacement']}") - print("\n Output files:") - print(" - docs/reference/shell_assets.json") - print(" - docs/reference/shell_assets.yaml") - print(" - docs/reference/shell_wrappers/ (Python wrappers)") - shell_stats = stats # Save for summary - - # 5. Extract environment variables - print("\n5. Extracting Environment Variables...") - print("-" * 40) - env_extractor = EnvironmentVariableExtractor(plandex_dir) - env_output_dir = Path("docs/reference") - env_extractor.save_results(env_output_dir) - env_results = env_extractor.extract_all() - stats = env_results["statistics"] - print(f"✓ Extracted {stats['total_variables']} environment variables") - print(f" - Documented variables: {stats['documented_variables']}") - print(f" - Code-only variables: {stats['code_only_variables']}") - print(f" - Variables requiring migration: {stats['migration_required']}") - print("\n Output files:") - print(" - docs/reference/env_variables.json") - print(" - docs/reference/env_variables.yaml") - print(" - docs/reference/env_mapping.txt") - print(" - docs/reference/env_migration_guide.md") - - # 6. Extract implicit behaviors - print("\n6. Extracting Implicit Runtime Behaviors...") - print("-" * 40) - behavior_extractor = ImplicitBehaviorExtractor(plandex_dir) - behaviors = behavior_extractor.extract_all() - behavior_output_dir = Path("docs/reference/behaviors") - behavior_extractor.save_results(behavior_output_dir) - - behavior_stats = behaviors["statistics"] - print(f"✓ Extracted {behavior_stats['total_behaviors']} behaviors") - print(f" - Categories: {', '.join(behavior_stats['categories'])}") - for cat, count in behavior_stats["behaviors_per_category"].items(): - print(f" - {cat}: {count} behaviors") - print("\n Output files:") - print(" - docs/reference/behaviors/implicit_behaviors.json") - print(" - docs/reference/behaviors/implicit_behaviors.yaml") - print(" - docs/reference/behaviors/implicit_behaviors.md") - - # 7. Generate workflow parity matrix - print("\n7. Generating Workflow Parity Matrix...") - print("-" * 40) - parity_extractor = WorkflowParityExtractor(plandex_dir) - parity_output_dir = Path("docs/reference/workflows") - parity_extractor.save_results(parity_output_dir) - parity_results = parity_extractor.extract_all() - parity_stats = parity_results["statistics"] - print(f"✓ Extracted {parity_stats['total_workflows']} workflows") - print(f" - Go components: {parity_stats['total_go_components']}") - print(f" - Python modules: {parity_stats['total_python_modules']}") - print(f" - Total stages: {parity_stats['total_stages']}") - print(" - Test coverage:") - for test_type, count in parity_stats["test_coverage"].items(): - print(f" - {test_type}: {count}") - print("\n Output files:") - print(" - docs/reference/workflows/workflow_parity.json") - print(" - docs/reference/workflows/workflow_parity.yaml") - print(" - docs/reference/workflows/workflow_parity.md") - - # 8. Identify cloud-only features - print("\n8. Identifying Cloud-Only Features...") - print("-" * 40) - cloud_extractor = CloudFeaturesExtractor(plandex_dir) - cloud_output_dir = Path("docs/reference/cloud") - cloud_extractor.save_results(cloud_output_dir) - cloud_results = cloud_extractor.extract_all() - cloud_stats = cloud_results["statistics"] - print(f"✓ Identified {cloud_stats['total_features']} cloud features") - print(f" - To remove: {cloud_stats['by_action']['remove']}") - print(f" - To replace: {cloud_stats['by_action']['replace']}") - print(f" - High priority: {cloud_stats['by_priority']['high']}") - print(f" - Go files affected: {cloud_stats['go_files_affected']}") - print("\n Output files:") - print(" - docs/reference/cloud/cloud_features.json") - print(" - docs/reference/cloud/cloud_features.yaml") - print(" - docs/reference/cloud/cloud_features.md") - - print("\n" + "=" * 70) - print("Discovery Summary") - print("=" * 70) - total_cmds = cli_inventory["statistics"]["total_commands"] - total_endpoints = server_inventory["statistics"]["total_endpoints"] - print(f"✓ CLI inventory extracted: {total_cmds} commands") - print(f"✓ Server endpoints extracted: {total_endpoints} endpoints") - print(f"✓ Data contracts extracted: {total_structs} structs, {total_enums} enums") - print(f"✓ Shell assets cataloged: {shell_stats['total_scripts']} scripts") - env_var_count = env_results["statistics"]["total_variables"] - print(f"✓ Environment variables extracted: {env_var_count} variables") - print( - f"✓ Runtime behaviors extracted: {behavior_stats['total_behaviors']} behaviors" - ) - workflow_count = parity_stats["total_workflows"] - print(f"✓ Workflow parity matrix: {workflow_count} workflows mapped") - cloud_count = cloud_stats["total_features"] - print(f"✓ Cloud features identified: {cloud_count} features") - - print("\nAll discovery tools completed successfully!") - print("\nNext steps:") - print("1. Review generated artifacts in docs/reference/") - print("2. Begin Phase 1: Architecture Definition") - print("3. Update implementation_plan.md with findings") - - -if __name__ == "__main__": - main() diff --git a/src/cleveragents/discovery/server_endpoints.py b/src/cleveragents/discovery/server_endpoints.py deleted file mode 100644 index fbef4e2d3..000000000 --- a/src/cleveragents/discovery/server_endpoints.py +++ /dev/null @@ -1,453 +0,0 @@ -"""Server endpoint extraction tool for discovering Plandex API routes.""" - -import json -import re -from pathlib import Path -from typing import Any - -import yaml -from pydantic import BaseModel, ConfigDict, Field - - -class Endpoint(BaseModel): - """Represents a server API endpoint.""" - - path: str - method: str - handler: str - is_streaming: bool = False - requires_auth: bool = True - path_params: list[str] = Field(default_factory=list) - description: str = "" - category: str = "" - - model_config = ConfigDict(validate_assignment=True) - - -class ServerEndpointExtractor: - """Extracts server endpoint inventory from Plandex Go server code.""" - - def __init__(self, plandex_path: str = "/app/plandex"): - self.plandex_path = Path(plandex_path) - self.server_path = self.plandex_path / "app" / "server" - self.endpoints: list[Endpoint] = [] - self.handler_descriptions: dict[str, str] = {} - - # Provide a deterministic mock dataset for local runs without Plandex - self._mock_endpoints: list[Endpoint] = [ - Endpoint( - path="/health", - method="GET", - handler="HealthHandler", - is_streaming=False, - requires_auth=False, - path_params=[], - category="System", - ), - Endpoint( - path="/version", - method="GET", - handler="VersionHandler", - is_streaming=False, - requires_auth=False, - path_params=[], - category="System", - ), - Endpoint( - path="/accounts/sign_in", - method="POST", - handler="SignInHandler", - is_streaming=False, - requires_auth=False, - path_params=[], - category="Authentication", - ), - Endpoint( - path="/projects/{projectId}/plans/{planId}", - method="GET", - handler="GetPlanHandler", - is_streaming=False, - requires_auth=True, - path_params=["projectId", "planId"], - category="Plans", - ), - Endpoint( - path="/projects/{projectId}/plans/{planId}/stream", - method="GET", - handler="PlanStreamHandler", - is_streaming=True, - requires_auth=True, - path_params=["projectId", "planId"], - category="Plans", - ), - Endpoint( - path="/projects/{projectId}/models", - method="GET", - handler="ListModelsHandler", - is_streaming=False, - requires_auth=True, - path_params=["projectId"], - category="Models", - ), - Endpoint( - path="/models", - method="GET", - handler="ModelsListHandler", - is_streaming=False, - requires_auth=True, - path_params=[], - category="Models", - ), - ] - - def _load_mock_endpoints(self) -> None: - """Populate endpoints with a rich mock dataset for test runs.""" - # Start with the base mocks that cover streaming, public, and path params - self.endpoints = list(self._mock_endpoints) - - # Add synthetic endpoints to satisfy count and coverage expectations - categories = ["Authentication", "Plans", "Projects", "Models"] - for idx in range(1, 76): - category = categories[idx % len(categories)] - path = f"/api/{category.lower()}/{idx}" - path_params: list[str] = [] - if category in {"Plans", "Projects"}: - path = f"/api/{category.lower()}/{{projectId}}/{idx}" - path_params = ["projectId"] - if category == "Plans" and idx % 5 == 0: - path = f"/api/plans/{{projectId}}/{{planId}}/{idx}" - path_params = ["projectId", "planId"] - if category == "Models" and idx % 4 == 0: - path = f"/api/models/{{modelId}}/{idx}" - path_params = ["modelId"] - - self.endpoints.append( - Endpoint( - path=path, - method="GET" if idx % 3 else "POST", - handler=f"{category}Handler{idx}", - is_streaming=bool(idx % 20 == 0), - requires_auth=not path.startswith("/health"), - path_params=path_params, - category=category, - ) - ) - - def extract_endpoints(self) -> dict[str, Any]: - """Extract all server endpoints from the Go code. - - Falls back to a rich mock inventory when the Plandex repository isn't - available so Behave scenarios can still validate structure locally. - """ - # Clear endpoints list to ensure fresh extraction - self.endpoints = [] - - # Parse routes file when the real repo is present; otherwise use mocks - routes_file = self.server_path / "routes" / "routes.go" - if routes_file.exists(): - self._parse_routes_file(routes_file) - handlers_dir = self.server_path / "handlers" - if handlers_dir.exists(): - self._parse_handler_descriptions(handlers_dir) - else: - self._load_mock_endpoints() - - # Categorize endpoints (applies to both real and mock data) - self._categorize_endpoints() - - return self._build_inventory() - - def _parse_routes_file(self, file_path: Path) -> None: - """Parse routes.go to extract endpoint definitions.""" - content = file_path.read_text() - - # Pattern to match HandlePlandexFn calls with handlers and inline functions - # Example 1: HandlePlandexFn(r, prefix+"/accounts/sign_in", false, - # handlers.SignInHandler).Methods("POST") - # Example 2: HandlePlandexFn(r, "/health", false, - # func(w http.ResponseWriter, r *http.Request) { - pattern1 = ( - r'HandlePlandexFn\(r,\s*(?:prefix\s*\+\s*)?["\']([^"\']+)["\']\s*,' - r"\s*(true|false)\s*,\s*handlers\.(\w+)\)" - r'(?:\.Methods\(["\'](\w+)["\']\))?' - ) - pattern2 = ( - r'HandlePlandexFn\(r,\s*["\']([^"\']+)["\']\s*,\s*(true|false)\s*,\s*func\(' - ) - - # First, match handlers with handler references - for match in re.finditer(pattern1, content): - path = match.group(1) - is_streaming = match.group(2) == "true" - handler = match.group(3) - method = match.group(4) or "GET" - - # Extract path parameters - path_params = re.findall(r"\{(\w+)\}", path) - - endpoint = Endpoint( - path=path, - method=method, - handler=handler, - is_streaming=is_streaming, - path_params=path_params, - ) - self.endpoints.append(endpoint) - - # Second, match inline function handlers (like health and version) - for match in re.finditer(pattern2, content): - path = match.group(1) - is_streaming = match.group(2) == "true" - - # For inline functions, derive handler name from path - handler = path.strip("/").replace("/", "_").title() + "Handler" - - endpoint = Endpoint( - path=path, - method="GET", # These typically are GET requests - handler=handler, - is_streaming=is_streaming, - path_params=[], - ) - self.endpoints.append(endpoint) - - def _parse_handler_descriptions(self, handlers_dir: Path) -> None: - """Parse handler files to extract descriptions.""" - for handler_file in handlers_dir.glob("*.go"): - content = handler_file.read_text() - - # Try to extract handler function comments - # Pattern: // Comment before function\nfunc HandlerName( - pattern = r"//\s*(.+?)\nfunc\s+(\w+Handler)\s*\(" - - for match in re.finditer(pattern, content, re.MULTILINE): - description = match.group(1).strip() - handler_name = match.group(2) - self.handler_descriptions[handler_name] = description - - def _categorize_endpoints(self) -> None: - """Categorize endpoints based on their paths.""" - for endpoint in self.endpoints: - # Update description from handler descriptions - if endpoint.handler in self.handler_descriptions: - endpoint.description = self.handler_descriptions[endpoint.handler] - - path = endpoint.path - # Always normalize system endpoints to be public - if path in ["/health", "/version"]: - endpoint.category = "System" - endpoint.requires_auth = False - continue - - # Respect pre-set categories when present (used by mocks) - if endpoint.category: - continue - - # Determine category based on path - if "/accounts" in path or "/sign_in" in path or "/sign_out" in path: - endpoint.category = "Authentication" - elif "/orgs" in path: - endpoint.category = "Organizations" - elif "/users" in path: - endpoint.category = "Users" - elif "/invites" in path: - endpoint.category = "Invitations" - elif "/projects" in path: - endpoint.category = "Projects" - elif "/plans" in path: - if "/context" in path: - endpoint.category = "Plan Context" - elif "/convo" in path: - endpoint.category = "Plan Conversation" - elif "/branches" in path: - endpoint.category = "Plan Branches" - elif "/settings" in path or "/config" in path: - endpoint.category = "Plan Settings" - else: - endpoint.category = "Plans" - elif ( - "/custom_models" in path - or "/custom_providers" in path - or "/model_sets" in path - or path.startswith("/models") - or path.startswith("/api/models") - ): - endpoint.category = "Models" - elif "/file_map" in path: - endpoint.category = "File Management" - elif "/default_settings" in path or "/org_user_config" in path: - endpoint.category = "Settings" - elif path.startswith("/auth/"): - endpoint.category = "Authentication" - endpoint.requires_auth = False - else: - endpoint.category = "Other" - - def _build_inventory(self) -> dict[str, Any]: - """Build the complete inventory structure.""" - # Group endpoints by category - by_category: dict[str, list[dict[str, Any]]] = {} - for endpoint in self.endpoints: - category = endpoint.category - if category not in by_category: - by_category[category] = [] - by_category[category].append(endpoint.model_dump()) - - # Count statistics - methods_count: dict[str, int] = {} - - for endpoint in self.endpoints: - method = endpoint.method - methods_count[method] = methods_count.get(method, 0) + 1 - - stats: dict[str, Any] = { - "total_endpoints": len(self.endpoints), - "streaming_endpoints": sum(1 for e in self.endpoints if e.is_streaming), - "categories": len(by_category), - "methods": methods_count, - } - - return { - "metadata": { - "source": str(self.server_path), - "endpoints_count": len(self.endpoints), - "categories_count": len(by_category), - }, - "statistics": stats, - "endpoints_by_category": by_category, - "all_endpoints": [e.model_dump() for e in self.endpoints], - } - - def save_inventory(self, output_dir: str = "docs/reference") -> tuple[str, str]: - """Save the endpoint inventory to files.""" - output_path = Path(output_dir) - output_path.mkdir(parents=True, exist_ok=True) - - inventory = self.extract_endpoints() - - # Save as JSON - json_path = output_path / "server_endpoints.json" - with open(json_path, "w") as f: - json.dump(inventory, f, indent=2) - - # Save as YAML - yaml_path = output_path / "server_endpoints.yaml" - with open(yaml_path, "w") as f: - yaml.dump(inventory, f, default_flow_style=False, sort_keys=False) - - # Generate OpenAPI spec - openapi_spec = self._generate_openapi_spec(inventory) - openapi_path = output_path / "server_api.yaml" - with open(openapi_path, "w") as f: - yaml.dump(openapi_spec, f, default_flow_style=False, sort_keys=False) - - return str(yaml_path), str(json_path) - - def _generate_openapi_spec(self, inventory: dict[str, Any]) -> dict[str, Any]: - """Generate an OpenAPI specification from the inventory.""" - spec: dict[str, Any] = { - "openapi": "3.0.0", - "info": { - "title": "CleverAgents API (Plandex Migration)", - "version": "1.0.0", - "description": ( - "API specification extracted from Plandex server " - "for CleverAgents migration" - ), - }, - "servers": [ - { - "url": "http://localhost:8080", - "description": "Local development server", - } - ], - "paths": {}, - "components": { - "securitySchemes": { - "sessionAuth": { - "type": "apiKey", - "in": "header", - "name": "Authorization", - } - } - }, - } - - # Build paths from endpoints - paths_dict: dict[str, Any] = spec["paths"] - for endpoint_data in inventory["all_endpoints"]: - path = endpoint_data["path"] - method = endpoint_data["method"].lower() - - if path not in paths_dict: - paths_dict[path] = {} - - operation: dict[str, Any] = { - "summary": endpoint_data.get( - "description", f"{endpoint_data['handler']} handler" - ), - "operationId": endpoint_data["handler"], - "tags": [endpoint_data["category"]], - "responses": { - "200": {"description": "Successful response"}, - "401": {"description": "Unauthorized"}, - "500": {"description": "Internal server error"}, - }, - } - - # Add path parameters - if endpoint_data["path_params"]: - params_list: list[dict[str, Any]] = [] - for param in endpoint_data["path_params"]: - params_list.append( - { - "name": param, - "in": "path", - "required": True, - "schema": {"type": "string"}, - } - ) - operation["parameters"] = params_list - - # Add security if required - if endpoint_data["requires_auth"]: - operation["security"] = [{"sessionAuth": []}] - - # Note if streaming - if endpoint_data["is_streaming"]: - operation["x-streaming"] = True - responses_200 = operation["responses"]["200"] - if isinstance(responses_200, dict): - responses_200["content"] = { - "text/event-stream": { - "schema": { - "type": "string", - "description": "Server-sent events stream", - } - } - } - - paths_dict[path][method] = operation - - return spec - - -def main() -> None: - """Main function to run server endpoint extraction.""" - extractor = ServerEndpointExtractor() - yaml_path, json_path = extractor.save_inventory() - - # Print summary - inventory = extractor.extract_endpoints() - print("Server Endpoint Extraction Complete:") - print(f" Total endpoints: {inventory['statistics']['total_endpoints']}") - print(f" Streaming endpoints: {inventory['statistics']['streaming_endpoints']}") - print(f" Categories: {inventory['statistics']['categories']}") - print(f" Methods: {inventory['statistics']['methods']}") - print(f" Saved to: {yaml_path}") - print(f" {json_path}") - print(" OpenAPI spec: docs/reference/server_api.yaml") - - -if __name__ == "__main__": - main() diff --git a/src/cleveragents/discovery/shell_assets.py b/src/cleveragents/discovery/shell_assets.py deleted file mode 100644 index db8633c9e..000000000 --- a/src/cleveragents/discovery/shell_assets.py +++ /dev/null @@ -1,368 +0,0 @@ -#!/usr/bin/env python3 -"""Shell asset extraction and conversion module for CleverAgents migration.""" - -import json -import re -from pathlib import Path -from typing import Any - -import yaml -from pydantic import BaseModel, ConfigDict, Field - - -class ShellScript(BaseModel): - """Representation of a shell script with metadata.""" - - path: str - name: str - description: str = "" - dependencies: list[str] = Field(default_factory=list) - environment_vars: list[str] = Field(default_factory=list) - inputs: list[str] = Field(default_factory=list) - outputs: list[str] = Field(default_factory=list) - side_effects: list[str] = Field(default_factory=list) - commands_used: set[str] = Field(default_factory=set) - functions_defined: list[str] = Field(default_factory=list) - idempotent: bool = False - requires_docker: bool = False - requires_git: bool = False - python_replacement_suggested: bool = False - content: str = "" - - model_config = ConfigDict(validate_assignment=True) - - -class ShellAssetExtractor: - """Extract and catalog shell scripts from Plandex repository.""" - - def __init__(self, plandex_dir: str = "plandex"): - """Initialize the extractor with the Plandex directory path.""" - self.plandex_dir = Path(plandex_dir) - self.scripts: list[ShellScript] = [] - self.environment_map: dict[str, list[str]] = {} - - def extract_all(self) -> dict[str, Any]: - """Extract and catalog all shell scripts.""" - # Find all shell scripts - self._find_scripts() - - # Analyze each script - for script in self.scripts: - self._analyze_script(script) - - # Build environment variable map - self._build_env_map() - - return self._to_dict() - - def _find_scripts(self) -> None: - """Find all shell scripts in the repository.""" - patterns = ["*.sh", "*.bash"] - search_dirs = [ - self.plandex_dir / "app", - self.plandex_dir / "test", - self.plandex_dir / "scripts", - ] - - for search_dir in search_dirs: - if not search_dir.exists(): - continue - - for pattern in patterns: - for script_path in search_dir.rglob(pattern): - relative_path = script_path.relative_to(self.plandex_dir) - script = ShellScript( - path=str(relative_path), - name=script_path.name, - ) - self.scripts.append(script) - - def _analyze_script(self, script: ShellScript) -> None: - """Analyze a shell script for metadata.""" - script_path = self.plandex_dir / script.path - - try: - with open(script_path, encoding="utf-8") as f: - content = f.read() - script.content = content - except Exception as e: - print(f"Error reading {script_path}: {e}") - return - - # Extract description from comments - desc_match = re.search(r"^#\s+(.+?)(?:\n|$)", content, re.MULTILINE) - if desc_match: - script.description = desc_match.group(1).strip() - - # Find environment variables used - env_vars = re.findall(r"\$\{?([A-Z_][A-Z0-9_]*)\}?", content) - script.environment_vars = list(set(env_vars)) - - # Find commands used - commands = self._extract_commands(content) - script.commands_used = commands - - # Check for specific dependencies - if "docker" in commands or "docker-compose" in commands: - script.requires_docker = True - - if "git" in commands: - script.requires_git = True - - # Find function definitions - functions = re.findall( - r"^function\s+(\w+)|^(\w+)\s*\(\)", content, re.MULTILINE - ) - script.functions_defined = [f[0] or f[1] for f in functions if f[0] or f[1]] - - # Analyze based on script name and content - self._analyze_by_type(script, content) - - def _extract_commands(self, content: str) -> set[str]: - """Extract commands used in the script.""" - commands: set[str] = set() - - # Common command patterns - cmd_patterns = [ - r"(?:^|\s)([a-z][a-z0-9_-]+)(?:\s|$)", # Simple commands - r"command\s+-v\s+(\w+)", # command -v checks - r"which\s+(\w+)", # which checks - ] - - for pattern in cmd_patterns: - matches = re.findall(pattern, content, re.MULTILINE) - commands.update(matches) - - # Filter out shell builtins and variables - builtins = { - "if", - "then", - "else", - "elif", - "fi", - "for", - "while", - "do", - "done", - "case", - "esac", - "function", - "return", - "exit", - "echo", - "cd", - "pwd", - "export", - "source", - "shift", - "set", - } - - return commands - builtins - - def _analyze_by_type(self, script: ShellScript, content: str) -> None: - """Analyze script based on its type/purpose.""" - name_lower = script.name.lower() - - if "test" in name_lower: - script.inputs.append("Test project directory") - script.outputs.append("Test results") - script.side_effects.append("Creates/modifies test artifacts") - - elif "start_local" in name_lower: - script.description = "Start local development environment with Docker" - script.inputs.append("Docker compose configuration") - script.outputs.append("Running containers") - script.side_effects.append("Starts Docker containers") - script.side_effects.append("Opens network ports") - script.python_replacement_suggested = True - - elif "wait-for-it" in name_lower: - script.description = "Wait for a service to be available" - script.inputs.append("Host and port to check") - script.outputs.append("Exit code indicating availability") - script.idempotent = True - - elif "dev" in name_lower: - script.description = "Development environment setup or commands" - script.side_effects.append("Modifies development environment") - - elif "gen" in name_lower or "provider" in name_lower: - script.description = "Code generation script" - script.outputs.append("Generated code files") - script.side_effects.append("Creates/modifies source files") - - # Check for idempotency indicators - if "mkdir -p" in content or "test -" in content or "[ -" in content: - script.idempotent = True - - def _build_env_map(self) -> None: - """Build a map of environment variables to scripts.""" - for script in self.scripts: - for env_var in script.environment_vars: - if env_var not in self.environment_map: - self.environment_map[env_var] = [] - self.environment_map[env_var].append(script.path) - - def _to_dict(self) -> dict[str, Any]: - """Convert extracted data to dictionary format.""" - return { - "scripts": [ - { - "path": s.path, - "name": s.name, - "description": s.description, - "dependencies": s.dependencies, - "environment_vars": s.environment_vars, - "inputs": s.inputs, - "outputs": s.outputs, - "side_effects": s.side_effects, - "commands_used": sorted(list(s.commands_used)), - "functions_defined": s.functions_defined, - "idempotent": s.idempotent, - "requires_docker": s.requires_docker, - "requires_git": s.requires_git, - "python_replacement_suggested": s.python_replacement_suggested, - } - for s in self.scripts - ], - "environment_map": self.environment_map, - "statistics": { - "total_scripts": len(self.scripts), - "docker_required": sum(1 for s in self.scripts if s.requires_docker), - "git_required": sum(1 for s in self.scripts if s.requires_git), - "idempotent": sum(1 for s in self.scripts if s.idempotent), - "python_replacement": sum( - 1 for s in self.scripts if s.python_replacement_suggested - ), - }, - } - - def save_catalog(self, output_dir: str = "docs/reference") -> None: - """Save the shell script catalog to files.""" - output_path = Path(output_dir) - output_path.mkdir(parents=True, exist_ok=True) - - catalog = self.extract_all() - - # Save as YAML - yaml_path = output_path / "shell_assets.yaml" - with open(yaml_path, "w") as f: - yaml.dump(catalog, f, default_flow_style=False, sort_keys=False) - print(f"Shell asset catalog saved to {yaml_path}") - - # Save as JSON - json_path = output_path / "shell_assets.json" - with open(json_path, "w") as f: - json.dump(catalog, f, indent=2) - print(f"Shell asset catalog saved to {json_path}") - - # Generate Python wrappers - self._generate_wrappers(output_path) - - def _generate_wrappers(self, output_dir: Path) -> None: - """Generate Python wrapper functions for shell scripts.""" - wrappers_dir = output_dir / "shell_wrappers" - wrappers_dir.mkdir(parents=True, exist_ok=True) - - wrapper_template = '''"""Python wrapper for {script_name}""" - -import subprocess -import os -from pathlib import Path -from typing import Optional, Dict, Any - - -def run_{function_name}( - working_dir: Optional[str] = None, - env: Optional[Dict[str, str]] = None, - capture_output: bool = True, - check: bool = True, -) -> subprocess.CompletedProcess: - """ - Run {script_name} shell script. - - Original script: {script_path} - Description: {description} - Requires Docker: {requires_docker} - Requires Git: {requires_git} - - Args: - working_dir: Directory to run the script in - env: Environment variables to set - capture_output: Whether to capture stdout/stderr - check: Whether to raise on non-zero exit code - - Returns: - CompletedProcess with the result - """ - script_path = (Path(__file__).parent.parent.parent.parent / - "plandex" / "{script_path}") - - if not script_path.exists(): - raise FileNotFoundError(f"Script not found: {{script_path}}") - - # Merge environment variables - run_env = os.environ.copy() - if env: - run_env.update(env) - - # Required environment variables: {env_vars} - - return subprocess.run( - ["bash", str(script_path)], - cwd=working_dir, - env=run_env, - capture_output=capture_output, - check=check, - text=True, - ) -''' - - for script in self.scripts: - if not script.python_replacement_suggested: - continue - - function_name = ( - script.name.replace("-", "_").replace(".sh", "").replace(".bash", "") - ) - wrapper_content = wrapper_template.format( - script_name=script.name, - script_path=script.path, - function_name=function_name, - description=script.description, - requires_docker=script.requires_docker, - requires_git=script.requires_git, - env_vars=", ".join(script.environment_vars), - ) - - wrapper_path = wrappers_dir / f"{function_name}.py" - with open(wrapper_path, "w") as f: - f.write(wrapper_content) - - print(f"Python wrappers generated in {wrappers_dir}") - - -def main() -> None: - """Main entry point for shell asset extraction.""" - extractor = ShellAssetExtractor() - extractor.save_catalog() - - # Print summary - catalog = extractor.extract_all() - stats = catalog["statistics"] - - print("\nShell Asset Extraction Summary:") - print(f" Total scripts found: {stats['total_scripts']}") - print(f" Scripts requiring Docker: {stats['docker_required']}") - print(f" Scripts requiring Git: {stats['git_required']}") - print(f" Idempotent scripts: {stats['idempotent']}") - print(f" Suggested for Python replacement: {stats['python_replacement']}") - - print("\nEnvironment variables used:") - for var, scripts in sorted(catalog["environment_map"].items())[:10]: - print(f" {var}: used in {len(scripts)} script(s)") - - -if __name__ == "__main__": - main() diff --git a/src/cleveragents/discovery/workflow_parity.py b/src/cleveragents/discovery/workflow_parity.py deleted file mode 100644 index 6a3d7bab0..000000000 --- a/src/cleveragents/discovery/workflow_parity.py +++ /dev/null @@ -1,779 +0,0 @@ -""" -Workflow parity matrix generator for Plandex to CleverAgents migration. -Maps end-to-end workflows from Go implementation to Python modules. -""" - -import json -from pathlib import Path -from typing import Any - -import yaml - - -class WorkflowParityExtractor: - """Extract and map workflows from Plandex to CleverAgents Python modules.""" - - def __init__(self, plandex_dir: Path | None = None): - """Initialize the workflow parity extractor.""" - self.plandex_dir = plandex_dir or Path("plandex") - self.workflows: dict[str, dict[str, Any]] = {} - - # Define core workflow categories - self.workflow_categories = { - "plan_lifecycle": "Plan creation, building, applying, and archiving", - "context_management": "Context loading, modification, and auto-detection", - "execution_flows": "Command execution, auto-debug, and rollback", - "branching": "Branch creation, switching, merging, and diff management", - "collaboration": "Team invites, sharing, and permissions", - "model_management": ( - "Model selection, custom models, and provider configuration" - ), - "authentication": "Login, logout, session management, and API keys", - "configuration": "Settings, environment variables, and config files", - "streaming": "Real-time updates, logs, and progress tracking", - "background_jobs": "Async tasks, retries, and job scheduling", - } - - def extract_all(self) -> dict[str, Any]: - """Extract all workflows and create parity matrix.""" - self._extract_plan_workflows() - self._extract_context_workflows() - self._extract_exec_workflows() - self._extract_branch_workflows() - self._extract_auth_workflows() - self._extract_model_workflows() - self._extract_config_workflows() - self._extract_collaboration_workflows() - self._extract_streaming_workflows() - self._extract_background_workflows() - - # Create parity matrix - matrix = self._create_parity_matrix() - - # Generate statistics - stats = self._generate_statistics() - - return { - "workflows": self.workflows, - "matrix": matrix, - "statistics": stats, - "categories": self.workflow_categories, - } - - def _extract_plan_workflows(self): - """Extract plan-related workflows.""" - self.workflows["plan_create"] = { - "category": "plan_lifecycle", - "description": "Create a new plan with initial context", - "go_components": [ - "app/cli/cmd/plan.go", - "app/cli/cmd/new.go", - "app/cli/plan_exec/plan_exec.go", - "app/server/handlers/plan_handlers.go", - "app/server/db/plan_helpers.go", - ], - "stages": [ - { - "name": "initialization", - "description": "Create plan structure and metadata", - }, - { - "name": "context_setup", - "description": "Set up initial context and files", - }, - { - "name": "model_selection", - "description": "Choose default model for the plan", - }, - { - "name": "persistence", - "description": "Save plan to database/filesystem", - }, - ], - "python_modules": [ - "cleveragents.domain.plans", - "cleveragents.application.plan_service", - "cleveragents.cli.commands.plan", - ], - "test_coverage": { - "behave": ["features/plans.feature"], - "robot": ["robot/plan_lifecycle.robot"], - "go_tests": ["app/cli/cmd/plan_test.go"], - }, - "dependencies": ["authentication", "model_management", "persistence"], - "notes": "Must maintain backward compatibility with existing plan formats", - } - - self.workflows["plan_build"] = { - "category": "plan_lifecycle", - "description": "Build plan by processing prompts through AI models", - "go_components": [ - "app/cli/cmd/tell.go", - "app/cli/cmd/continue.go", - "app/cli/plan_exec/plan_build.go", - "app/server/handlers/build_handlers.go", - "app/shared/plan_build.go", - ], - "stages": [ - { - "name": "prompt_processing", - "description": "Process user prompts and context", - }, - { - "name": "model_interaction", - "description": "Send to AI model and get response", - }, - { - "name": "diff_generation", - "description": "Generate diffs from AI response", - }, - {"name": "validation", "description": "Validate generated changes"}, - { - "name": "storage", - "description": "Store diffs and conversation history", - }, - ], - "python_modules": [ - "cleveragents.application.build_service", - "cleveragents.domain.diffs", - "cleveragents.infrastructure.ai_providers", - "cleveragents.cli.commands.tell", - ], - "test_coverage": { - "behave": ["features/plan_build.feature"], - "robot": ["robot/build_workflow.robot"], - }, - "dependencies": ["model_management", "diff_storage", "streaming"], - "notes": "Streaming updates must match Go implementation timing", - } - - self.workflows["plan_apply"] = { - "category": "plan_lifecycle", - "description": "Apply plan changes to files with review and confirmation", - "go_components": [ - "app/cli/cmd/apply.go", - "app/cli/plan_exec/apply_plan.go", - "app/server/handlers/apply_handlers.go", - "app/shared/apply.go", - ], - "stages": [ - {"name": "diff_preview", "description": "Show pending changes to user"}, - {"name": "confirmation", "description": "Get user confirmation"}, - {"name": "file_updates", "description": "Apply diffs to files"}, - {"name": "git_operations", "description": "Optional git commit"}, - {"name": "cleanup", "description": "Clean up temporary files"}, - ], - "python_modules": [ - "cleveragents.application.apply_service", - "cleveragents.domain.file_operations", - "cleveragents.infrastructure.git_integration", - "cleveragents.cli.commands.apply", - ], - "test_coverage": { - "behave": ["features/apply.feature"], - "robot": ["robot/apply_workflow.robot"], - }, - "dependencies": ["diff_management", "file_operations", "git_integration"], - "notes": "Must handle merge conflicts and rollback on failure", - } - - def _extract_context_workflows(self): - """Extract context management workflows.""" - self.workflows["context_load"] = { - "category": "context_management", - "description": "Load files and directories into plan context", - "go_components": [ - "app/cli/cmd/context.go", - "app/cli/cmd/load.go", - "app/cli/lib/context_loader.go", - "app/server/db/context_helpers.go", - ], - "stages": [ - { - "name": "path_resolution", - "description": "Resolve file paths and globs", - }, - {"name": "content_reading", "description": "Read file contents"}, - {"name": "filtering", "description": "Apply ignore patterns"}, - {"name": "indexing", "description": "Index content for search"}, - {"name": "storage", "description": "Store in context database"}, - ], - "python_modules": [ - "cleveragents.domain.context", - "cleveragents.application.context_service", - "cleveragents.infrastructure.file_loader", - "cleveragents.cli.commands.context", - ], - "test_coverage": { - "behave": ["features/context.feature"], - "robot": ["robot/context_management.robot"], - }, - "dependencies": ["file_operations", "path_resolution", "indexing"], - "notes": "Auto-context detection must match Go heuristics", - } - - self.workflows["context_auto"] = { - "category": "context_management", - "description": "Automatically detect and load relevant context", - "go_components": [ - "app/cli/lib/context_auto.go", - "app/cli/lib/context_heuristics.go", - ], - "stages": [ - { - "name": "detection", - "description": "Detect project type and structure", - }, - {"name": "heuristics", "description": "Apply loading heuristics"}, - {"name": "filtering", "description": "Filter irrelevant files"}, - {"name": "loading", "description": "Load detected context"}, - ], - "python_modules": [ - "cleveragents.application.auto_context", - "cleveragents.domain.heuristics", - ], - "test_coverage": { - "behave": ["features/auto_context.feature"], - "robot": ["robot/auto_context.robot"], - }, - "dependencies": ["context_load", "project_detection"], - "notes": "Heuristics extracted in implicit behaviors discovery", - } - - def _extract_exec_workflows(self): - """Extract execution and debugging workflows.""" - self.workflows["exec_command"] = { - "category": "execution_flows", - "description": "Execute commands in plan context with capture", - "go_components": [ - "app/cli/cmd/exec.go", - "app/cli/plan_exec/exec_cmd.go", - "app/shared/exec.go", - ], - "stages": [ - { - "name": "command_parsing", - "description": "Parse command and arguments", - }, - { - "name": "environment_setup", - "description": "Set up execution environment", - }, - {"name": "execution", "description": "Run command with output capture"}, - { - "name": "result_processing", - "description": "Process output and errors", - }, - { - "name": "context_update", - "description": "Update context with results", - }, - ], - "python_modules": [ - "cleveragents.application.exec_service", - "cleveragents.infrastructure.process_runner", - "cleveragents.domain.exec_results", - ], - "test_coverage": { - "behave": ["features/exec.feature"], - "robot": ["robot/execution.robot"], - }, - "dependencies": [ - "process_isolation", - "output_capture", - "context_management", - ], - "notes": "Must support process groups and cgroup isolation", - } - - self.workflows["auto_debug"] = { - "category": "execution_flows", - "description": "Automatically debug and retry failed operations", - "go_components": [ - "app/cli/cmd/debug.go", - "app/cli/plan_exec/auto_debug.go", - "app/shared/debug.go", - ], - "stages": [ - {"name": "error_detection", "description": "Detect errors in output"}, - { - "name": "error_analysis", - "description": "Analyze error for fix strategy", - }, - {"name": "fix_generation", "description": "Generate fix with AI model"}, - {"name": "fix_application", "description": "Apply fix and retry"}, - {"name": "validation", "description": "Validate fix succeeded"}, - ], - "python_modules": [ - "cleveragents.application.debug_service", - "cleveragents.domain.error_analysis", - "cleveragents.infrastructure.ai_debug", - ], - "test_coverage": { - "behave": ["features/auto_debug.feature"], - "robot": ["robot/debug_workflow.robot"], - }, - "dependencies": ["error_detection", "model_interaction", "retry_logic"], - "notes": "Retry limits and backoff must match Go implementation", - } - - def _extract_branch_workflows(self): - """Extract branching and version control workflows.""" - self.workflows["branch_create"] = { - "category": "branching", - "description": "Create and switch plan branches", - "go_components": [ - "app/cli/cmd/branches.go", - "app/cli/lib/branch_helpers.go", - "app/server/db/branch_helpers.go", - ], - "stages": [ - {"name": "validation", "description": "Validate branch name"}, - {"name": "creation", "description": "Create branch structure"}, - {"name": "copying", "description": "Copy current state to branch"}, - {"name": "switching", "description": "Switch to new branch"}, - {"name": "persistence", "description": "Save branch metadata"}, - ], - "python_modules": [ - "cleveragents.domain.branches", - "cleveragents.application.branch_service", - "cleveragents.cli.commands.branches", - ], - "test_coverage": { - "behave": ["features/branches.feature"], - "robot": ["robot/branching.robot"], - }, - "dependencies": ["plan_management", "diff_storage", "state_management"], - "notes": "Branch switching must preserve unsaved changes", - } - - self.workflows["branch_merge"] = { - "category": "branching", - "description": "Merge branches with conflict resolution", - "go_components": ["app/cli/cmd/merge.go", "app/cli/lib/merge_helpers.go"], - "stages": [ - {"name": "diff_comparison", "description": "Compare branch diffs"}, - {"name": "conflict_detection", "description": "Detect merge conflicts"}, - {"name": "conflict_resolution", "description": "Resolve conflicts"}, - {"name": "merge_application", "description": "Apply merged changes"}, - {"name": "cleanup", "description": "Clean up merged branch"}, - ], - "python_modules": [ - "cleveragents.application.merge_service", - "cleveragents.domain.conflict_resolution", - ], - "test_coverage": { - "behave": ["features/merge.feature"], - "robot": ["robot/merge_workflow.robot"], - }, - "dependencies": [ - "diff_management", - "conflict_detection", - "state_management", - ], - "notes": "Must support manual and automatic conflict resolution", - } - - def _extract_auth_workflows(self): - """Extract authentication and session workflows.""" - self.workflows["auth_login"] = { - "category": "authentication", - "description": "User authentication and session establishment", - "go_components": [ - "app/cli/cmd/sign_in.go", - "app/cli/lib/auth.go", - "app/server/handlers/auth_handlers.go", - "app/server/db/user_helpers.go", - ], - "stages": [ - {"name": "credential_input", "description": "Get user credentials"}, - {"name": "authentication", "description": "Verify credentials"}, - {"name": "session_creation", "description": "Create session token"}, - {"name": "token_storage", "description": "Store token locally"}, - {"name": "verification", "description": "Verify session active"}, - ], - "python_modules": [ - "cleveragents.infrastructure.auth", - "cleveragents.domain.sessions", - "cleveragents.cli.commands.auth", - ], - "test_coverage": { - "behave": ["features/authentication.feature"], - "robot": ["robot/auth_workflow.robot"], - }, - "dependencies": ["user_management", "token_management", "encryption"], - "notes": "Must support both API key and email/password auth", - } - - def _extract_model_workflows(self): - """Extract model management workflows.""" - self.workflows["model_selection"] = { - "category": "model_management", - "description": "Select and configure AI models", - "go_components": [ - "app/cli/cmd/models.go", - "app/cli/cmd/set_model.go", - "app/cli/lib/models_sync.go", - "app/shared/ai_models.go", - ], - "stages": [ - {"name": "model_listing", "description": "List available models"}, - {"name": "capability_check", "description": "Check model capabilities"}, - {"name": "selection", "description": "Select model"}, - {"name": "validation", "description": "Validate API keys"}, - {"name": "configuration", "description": "Save model configuration"}, - ], - "python_modules": [ - "cleveragents.domain.models", - "cleveragents.application.model_service", - "cleveragents.infrastructure.model_providers", - "cleveragents.cli.commands.models", - ], - "test_coverage": { - "behave": ["features/models.feature"], - "robot": ["robot/model_management.robot"], - }, - "dependencies": [ - "provider_integration", - "api_key_management", - "model_catalog", - ], - "notes": "Model catalog refresh must be automated", - } - - def _extract_config_workflows(self): - """Extract configuration management workflows.""" - self.workflows["config_management"] = { - "category": "configuration", - "description": "Manage application configuration", - "go_components": [ - "app/cli/cmd/config.go", - "app/cli/lib/config.go", - "app/server/config/config.go", - ], - "stages": [ - {"name": "config_loading", "description": "Load configuration files"}, - {"name": "env_merging", "description": "Merge environment variables"}, - {"name": "validation", "description": "Validate configuration"}, - {"name": "application", "description": "Apply configuration"}, - {"name": "persistence", "description": "Save configuration changes"}, - ], - "python_modules": [ - "cleveragents.infrastructure.config", - "cleveragents.domain.settings", - "cleveragents.cli.commands.config", - ], - "test_coverage": { - "behave": ["features/configuration.feature"], - "robot": ["robot/config_management.robot"], - }, - "dependencies": ["file_operations", "env_variables", "validation"], - "notes": "Must support CLEVERAGENTS_ env vars exclusively", - } - - def _extract_collaboration_workflows(self): - """Extract team collaboration workflows.""" - self.workflows["team_invite"] = { - "category": "collaboration", - "description": "Invite team members and manage permissions", - "go_components": [ - "app/cli/cmd/invite.go", - "app/server/handlers/invite_handlers.go", - "app/server/db/invite_helpers.go", - ], - "stages": [ - {"name": "invite_creation", "description": "Create invite"}, - {"name": "notification", "description": "Send invite notification"}, - {"name": "acceptance", "description": "Process invite acceptance"}, - {"name": "permission_grant", "description": "Grant permissions"}, - {"name": "sync", "description": "Sync team state"}, - ], - "python_modules": [ - "cleveragents.domain.teams", - "cleveragents.application.invite_service", - "cleveragents.infrastructure.notifications", - ], - "test_coverage": { - "behave": ["features/collaboration.feature"], - "robot": ["robot/team_workflow.robot"], - }, - "dependencies": ["user_management", "permissions", "notifications"], - "notes": "Replace cloud invites with SMTP or local alternatives", - } - - def _extract_streaming_workflows(self): - """Extract streaming and real-time update workflows.""" - self.workflows["stream_updates"] = { - "category": "streaming", - "description": "Stream real-time updates during operations", - "go_components": [ - "app/cli/stream_tui/stream_tui.go", - "app/cli/lib/active_stream.go", - "app/server/handlers/stream_handlers.go", - ], - "stages": [ - {"name": "connection", "description": "Establish streaming connection"}, - {"name": "buffering", "description": "Buffer incoming chunks"}, - {"name": "rendering", "description": "Render updates to UI"}, - {"name": "error_handling", "description": "Handle connection errors"}, - {"name": "cleanup", "description": "Clean up on completion"}, - ], - "python_modules": [ - "cleveragents.infrastructure.streaming", - "cleveragents.application.stream_service", - "cleveragents.cli.ui.stream_renderer", - ], - "test_coverage": { - "behave": ["features/streaming.feature"], - "robot": ["robot/streaming.robot"], - }, - "dependencies": ["websockets", "ui_rendering", "backpressure"], - "notes": "Must handle reconnection and backpressure", - } - - def _extract_background_workflows(self): - """Extract background job workflows.""" - self.workflows["background_jobs"] = { - "category": "background_jobs", - "description": "Manage background tasks and job scheduling", - "go_components": [ - "app/server/db/job_helpers.go", - "app/server/workers/workers.go", - "app/cli/lib/background_tasks.go", - ], - "stages": [ - {"name": "job_creation", "description": "Create job definition"}, - {"name": "scheduling", "description": "Schedule job execution"}, - {"name": "execution", "description": "Execute job task"}, - {"name": "retry", "description": "Retry on failure"}, - {"name": "completion", "description": "Mark job complete"}, - ], - "python_modules": [ - "cleveragents.infrastructure.jobs", - "cleveragents.application.job_service", - "cleveragents.domain.background_tasks", - ], - "test_coverage": { - "behave": ["features/background_jobs.feature"], - "robot": ["robot/job_scheduling.robot"], - }, - "dependencies": ["task_queue", "retry_logic", "scheduling"], - "notes": "Use asyncio or celery for job management", - } - - def _create_parity_matrix(self) -> dict[str, dict[str, list[str]] | list[str]]: - """Create a parity matrix mapping Go components to Python modules.""" - matrix: dict[str, Any] = { - "go_to_python": {}, - "python_to_go": {}, - "coverage_gaps": [], - "implementation_order": [], - } - - # Map Go components to Python modules - for _workflow_id, workflow in self.workflows.items(): - for go_component in workflow.get("go_components", []): - if go_component not in matrix["go_to_python"]: - matrix["go_to_python"][go_component] = [] - matrix["go_to_python"][go_component].extend( - workflow.get("python_modules", []) - ) - - # Map Python modules to Go components - for py_module in workflow.get("python_modules", []): - if py_module not in matrix["python_to_go"]: - matrix["python_to_go"][py_module] = [] - matrix["python_to_go"][py_module].extend( - workflow.get("go_components", []) - ) - - # Identify coverage gaps - all_go_files: set[str] = set() - for workflow in self.workflows.values(): - all_go_files.update(workflow.get("go_components", [])) - - # Check for missing test coverage - for workflow_id, workflow in self.workflows.items(): - test_coverage = workflow.get("test_coverage", {}) - if not test_coverage.get("behave"): - matrix["coverage_gaps"].append(f"{workflow_id}: Missing Behave tests") - if not test_coverage.get("robot"): - matrix["coverage_gaps"].append(f"{workflow_id}: Missing Robot tests") - - # Determine implementation order based on dependencies - matrix["implementation_order"] = self._calculate_implementation_order() - - return matrix - - def _calculate_implementation_order(self) -> list[str]: - """Calculate optimal implementation order based on dependencies.""" - # Simple topological sort based on dependencies - ordered: list[str] = [] - visited: set[str] = set() - - def visit(workflow_id: str) -> None: - if workflow_id in visited: - return - visited.add(workflow_id) - - workflow = self.workflows.get(workflow_id, {}) - for dep in workflow.get("dependencies", []): - # Find workflows that provide this dependency - for wf_id, wf in self.workflows.items(): - if wf.get("category") == dep or dep in str(wf): - visit(wf_id) - - if workflow_id not in ordered: - ordered.append(workflow_id) - - # Visit all workflows - for workflow_id in self.workflows: - visit(workflow_id) - - return ordered - - def _generate_statistics(self) -> dict[str, Any]: - """Generate statistics about the workflows.""" - stats: dict[str, Any] = { - "total_workflows": len(self.workflows), - "workflows_per_category": {}, - "total_go_components": 0, - "total_python_modules": 0, - "total_stages": 0, - "test_coverage": { - "with_behave": 0, - "with_robot": 0, - "with_go_tests": 0, - "without_tests": 0, - }, - } - - go_components: set[str] = set() - python_modules: set[str] = set() - - for workflow in self.workflows.values(): - # Count by category - category = workflow.get("category", "unknown") - stats["workflows_per_category"][category] = ( - stats["workflows_per_category"].get(category, 0) + 1 - ) - - # Count components - go_components.update(workflow.get("go_components", [])) - python_modules.update(workflow.get("python_modules", [])) - - # Count stages - stats["total_stages"] += len(workflow.get("stages", [])) - - # Count test coverage - test_coverage = workflow.get("test_coverage", {}) - if test_coverage.get("behave"): - stats["test_coverage"]["with_behave"] += 1 - if test_coverage.get("robot"): - stats["test_coverage"]["with_robot"] += 1 - if test_coverage.get("go_tests"): - stats["test_coverage"]["with_go_tests"] += 1 - if not test_coverage: - stats["test_coverage"]["without_tests"] += 1 - - stats["total_go_components"] = len(go_components) - stats["total_python_modules"] = len(python_modules) - - return stats - - def save_results(self, output_dir: Path) -> tuple[Path, Path]: - """Save the workflow parity matrix to files.""" - output_dir.mkdir(parents=True, exist_ok=True) - - results = self.extract_all() - - # Save as JSON - json_file = output_dir / "workflow_parity.json" - with open(json_file, "w") as f: - json.dump(results, f, indent=2, default=str) - - # Save as YAML - yaml_file = output_dir / "workflow_parity.yaml" - with open(yaml_file, "w") as f: - yaml.dump(results, f, default_flow_style=False, sort_keys=False) - - # Generate Markdown documentation - self._generate_markdown_doc(results, output_dir) - - return json_file, yaml_file - - def _generate_markdown_doc(self, results: dict[str, Any], output_dir: Path): - """Generate markdown documentation for the parity matrix.""" - md_file = output_dir / "workflow_parity.md" - - with open(md_file, "w") as f: - f.write("# Workflow Parity Matrix\n\n") - f.write( - "This document maps Plandex Go workflows to " - "CleverAgents Python modules.\n\n" - ) - - # Write statistics - stats = results["statistics"] - f.write("## Summary Statistics\n\n") - f.write(f"- Total workflows: {stats['total_workflows']}\n") - f.write(f"- Go components: {stats['total_go_components']}\n") - f.write(f"- Python modules: {stats['total_python_modules']}\n") - f.write(f"- Total stages: {stats['total_stages']}\n\n") - - # Write workflows by category - f.write("## Workflows by Category\n\n") - for category, description in results["categories"].items(): - f.write(f"### {category.replace('_', ' ').title()}\n") - f.write(f"{description}\n\n") - - # Find workflows in this category - category_workflows = [ - (wf_id, wf) - for wf_id, wf in results["workflows"].items() - if wf.get("category") == category - ] - - for wf_id, workflow in category_workflows: - f.write(f"#### {wf_id.replace('_', ' ').title()}\n") - f.write(f"{workflow['description']}\n\n") - - # Write stages - f.write("**Stages:**\n") - for stage in workflow.get("stages", []): - f.write(f"1. {stage['name']}: {stage['description']}\n") - f.write("\n") - - # Write Python modules - f.write("**Python Modules:**\n") - for module in workflow.get("python_modules", []): - f.write(f"- `{module}`\n") - f.write("\n") - - # Write test coverage - test_coverage = workflow.get("test_coverage", {}) - if test_coverage: - f.write("**Test Coverage:**\n") - for test_type, tests in test_coverage.items(): - if tests: - f.write(f"- {test_type}: {', '.join(tests)}\n") - f.write("\n") - - # Write notes - if workflow.get("notes"): - f.write(f"**Notes:** {workflow['notes']}\n\n") - - # Write implementation order - f.write("## Recommended Implementation Order\n\n") - f.write("Based on dependency analysis:\n\n") - for i, wf_id in enumerate( - results["matrix"]["implementation_order"][:20], 1 - ): - workflow = results["workflows"].get(wf_id, {}) - f.write(f"{i}. **{wf_id}** - {workflow.get('description', 'N/A')}\n") - - # Write coverage gaps - if results["matrix"]["coverage_gaps"]: - f.write("\n## Coverage Gaps\n\n") - for gap in results["matrix"]["coverage_gaps"]: - f.write(f"- {gap}\n") diff --git a/src/cleveragents/domain/models/core/org.py b/src/cleveragents/domain/models/core/org.py index 5cbcbbb9e..4a3e26fc3 100644 --- a/src/cleveragents/domain/models/core/org.py +++ b/src/cleveragents/domain/models/core/org.py @@ -1,7 +1,7 @@ """Organization and billing domain models for CleverAgents. -Based on Phase 0 discovery stubs in ``docs/reference/contracts/stubs/data_models.py`` -with additional validation rules from ADR-004 (Pydantic Validation). +Based on Phase 0 discovery stubs with additional validation rules from ADR-004 +(Pydantic Validation). """ from __future__ import annotations