Conversation
…leak loadAgentsConfig() sets a package-global workspace-root override from agents.yaml dispatch.workspace_root. A full-core test (newCoreAgent) leaves it set, so a later test relying on CORE_WORKSPACE resolved the leaked path instead — TestCommands_Check_Good_BranchWorkspaceCount failed in-suite but passed alone. Export SetWorkspaceRootOverride and reset it in newTestCore so each test starts from clean workspace resolution (mirroring the agentic package's own internal test guard). Co-Authored-By: Virgil <virgil@lethean.io>
Real per-symbol tests for the testable helpers: defaultHubTokenFile, defaultHubAuditPath, optStringOr, publicSuffix, auditMetaString, toBytes, hostIsLoopback (commands_hub.go); defaultUserChatsPath + the chat --user guard (commands_chat.go); detectBinaryName (main.go). Co-Authored-By: Virgil <virgil@lethean.io>
CI already uploads coverage to Codecov (.github/workflows/ci.yml) but had no codecov.yml, so there was no gate to "start using". Add one configured as a ratchet: project status target=auto (a PR may not drop total coverage below the base, 1% noise threshold) + patch target=70% (new/changed lines must be reasonably covered, pulling the number up as files are touched). Ignore tests, examples, and the vendored externals. `task cov` writes go/coverage.out (the path codecov + SonarCloud both read) and prints the total, for local runs. Co-Authored-By: Virgil <virgil@lethean.io>
Good/Bad/Ugly for the pure map-walk helper: nested path resolves to the terminal string; missing key at any step yields ""; non-map intermediate or non-string terminal yields "". Co-Authored-By: Virgil <virgil@lethean.io>
…> 39.2%) Add newTestService — builds a real opencode Service against a temp-$HOME DuckDB KV store, resetting the process-global kvOnce before+after (the cross-test hazard host_config_mode_test.go documented but sidestepped). auth.go and enable.go had no test files at all (hence 0%). With the harness: - auth.go: ServerPassword, InstallID, authHeader (+ SeedDefaultProfile) - enable.go: IsEnabled default-false, setEnabled round-trip - host_config.go: MergeHostConfig create + idempotent re-merge Co-Authored-By: Virgil <virgil@lethean.io>
….8%) Two table tests over the previously-0% command surface: the 5 pipeline routers (empty/help action → OK, unknown action → error) and the 16 leaf placeholders (not-yet-implemented). No side effects — these print help and return. Co-Authored-By: Virgil <virgil@lethean.io>
cmdPlanShow's slug guard (usage + error) and cmdPlanList against an empty
workspace ("no plans" → OK). Read-only, no side effects.
Co-Authored-By: Virgil <virgil@lethean.io>
Both card-listers, both lanes (human + --json), always-OK. Co-Authored-By: Virgil <virgil@lethean.io>
Pure option->input mappers (resume/scan/watch/mirror, incl. watch's single- workspace fallback) and brainValuePresent (nil/empty/whitespace absent, non-empty present). Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
…trip) GetProfile empty-name guard + notfound code; SaveProfile empty-name guard + save→get roundtrip. Via the isolated kv-harness. Co-Authored-By: Virgil <virgil@lethean.io>
ToOpenCodeWire strips name/description; ListProfiles returns seeded default + saved; DeleteProfile guards (empty + default-floor) then deletes and confirms gone. Co-Authored-By: Virgil <virgil@lethean.io>
cmdExtract surfaces an unreadable --source error; cmdBranchDelete refuses without repo+branch (guard runs before any forge call). Co-Authored-By: Virgil <virgil@lethean.io>
handleIssue{Get,List,Create} + handlePR{Get,List,Merge,Close} each delegate to
their cmd* form, which refuses empty input before any forge call.
Co-Authored-By: Virgil <virgil@lethean.io>
SetWorkspaceRootOverride (abs/relative), LogDir/ConfDir/DataDir/AgentsConfigPath, pipelineIssueIsAudit (title markers) + pipelineIssueIsEpic, parseCreditBalance. Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
… platform) Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Assert each builds its request and calls the platform endpoint (mock records the hits), independent of the response-parse branch. Co-Authored-By: Virgil <virgil@lethean.io>
Drive the 11 remaining platform tools through their request-building paths (list/get tools reach the mock platform, the rest hit their guards). Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
…tchService Api\Fleet\FleetController (/v1/fleet/dispatch + /v1/fleet/stream) now runs on DispatchService over the unified tables; enqueue carries findings/changes/report and stats() preserves the /v1/fleet/stats contract from dispatch_jobs. Retire the now-orphaned FleetService + the RegisterNode/NodeHeartbeat/DeregisterNode/ CompleteTask/GetNextTask actions. Tests updated to the unified model and flagged UNRUN (framework suite can't be installed with forge offline; verify in CI). ListNodes/AssignTask/GetFleetStats + FleetNode/FleetTask stay — still used by the live FleetOverview admin (HubComponent), which is a separate UI migration. Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
…ers/ Verified each design's work is present in source before removal; the docs are redundant replication guides. Future superpowers output stays local (gitignored). Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
…ature docs in subfolders RFC specs live in plans/code/core/agent/; remove the stale repo duplicates (root + docs/ RFC*, flow/, plugins/, php-agent/, AX dup) and the index.md landing page. Reorganise the remaining feature docs into brain/, inference/, setup/. Repoint CLAUDE.md + architecture.md cross-references. Co-Authored-By: Virgil <virgil@lethean.io>
15 docs/<feature>/ stubs (one per code feature found in cmd/ + pkg/), each pointing at its source and the literal-docs-from-code rules. DOCS-TASK.md is the agent brief to fill them. Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
…m code (#215) Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
…(#218) Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
…m code (#220) Co-Authored-By: Virgil <virgil@lethean.io>
…om code (#221) Co-Authored-By: Virgil <virgil@lethean.io>
…tire DOCS-TASK All feature stubs are now written user guides; the fill-it brief has done its job. Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
… pages (#222) Each docs/<feature>/README.md is now a concise (~50-line) SEO-aware index that links to child detail pages. Split: cli (commands), dispatch (runners), plans (sessions), pipeline (closeout + orchestration). Trimmed: fleet, brain, inference (children already existed). Co-Authored-By: Virgil <virgil@lethean.io>
…rs (#223) New docs/providers/ catalogues the providers you dispatch to (claude/codex/gemini/vibe/ coderabbit remote, opencode + LEM/ollama local), split by model location, cross-linking dispatch/runners (native vs container) and inference (the local engine). Co-Authored-By: Virgil <virgil@lethean.io>
…der (#223) Split the monolithic dev guide into an index + building/testing/standards/extending/ plugins/configuration pages (folder = URL, README = concise index). Repoint CLAUDE.md. Co-Authored-By: Virgil <virgil@lethean.io>
core.Info is structured (msg + key/value pairs), not printf. "interval=%s" left m.interval as a key with no value, logging '(interval=%s) 2m0s=<nil>'. Now logs 'monitor: started interval=2m0s'. Co-Authored-By: Virgil <virgil@lethean.io>
…#225)
Mount the canonical dappco.re/go/cli layer via core.WithService(cli.Register)
in main.go — the CLI surfaces as a service like any other, no second *core.Cli.
Convert go.work off the banned ../orm/go and ../go-container/go relative refs
onto ./external/* submodules, and register external/{cli,orm,go-container}
(all at commits already on their origin/dev). Bump external/go to 4b0072a.
Co-Authored-By: Virgil <virgil@lethean.io>
Five messages.* events were broadcast with no handler. Add reactions: - H1 QueueDrained -> notify queue.status - H4 HarvestRejected-> notify harvest.status (with reason) - H5 InboxMessage -> notify inbox.status - H2 RateLimitDetected -> per-pool backoff (written under the runner.drain lock drainOne reads it through) + notify ratelimit.status; malformed duration notifies without freezing - H3 HarvestComplete -> runner notifies harvest.status; agentic.handleHarvestAutoPR re-dispatches agentic.auto-pr for the harvested branch's workspace Each ships a test that emits the event and asserts the reaction. Co-Authored-By: Virgil <virgil@lethean.io>
…224)
Exchange a short-lived, single-use 6-digit code (minted at app.lthn.ai/device)
for an AgentApiKey. Two unauthenticated, hard-throttled endpoints:
- POST v1/agent/auth/login -> { data: { key } } (Go AuthLoginOutput shape)
- POST v1/device/pair -> { data: { agent_api_key } } (Go fleet client shape)
The code is the proof; throttle:10,1 keeps the 6-digit space out of brute-force
reach. Backed by the DevicePairing model + agent_device_pairings migration and
Claim/Create/InvalidPairingCode actions; AuthController.login/pair drive them.
Routes tidied to use-imports along the way. Feature test in DevicePairingTest.
Also: gitignore php/vendor/ (regenerated from composer; never tracked).
In-progress — not PHP-suite verified this session (composer/phpunit not run).
Co-Authored-By: Virgil <virgil@lethean.io>
Preserve in-progress ContentController (149 lines) so the work isn't lost. Not yet wired into Routes/api.php — incomplete, committed for continuity. Co-Authored-By: Virgil <virgil@lethean.io>
Co-Authored-By: Virgil <virgil@lethean.io>
|
Caution Review failedAn error occurred during the review process. Please try again later. Warning Billing warning: we have not been able to collect payment for this subscription for more than 72 hours. Please update the payment method or pay any pending invoices in Billing to avoid service interruption. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…11.0 Drops the go.work override; deps resolve from released tags. Ports ~115 sites to core.Result (Fs.IsFile/IsDir/Exists->.OK, Fs.TempDir/store.New->Result). DuckDB -> duckdb-go/v2 fork; orm pinned to go/v0.1.1. Co-Authored-By: Virgil <virgil@lethean.io>
|
| from typing import Iterable | ||
|
|
||
|
|
||
| DEFAULT_SERVER = "/private/tmp/core-agent-mlx-vlm/bin/mlx_vlm.server" |
|
|
||
|
|
||
| DEFAULT_SERVER = "/private/tmp/core-agent-mlx-vlm/bin/mlx_vlm.server" | ||
| DEFAULT_APC_PATH = "/private/tmp/mlx-vlm-apc" |
|
|
||
| DEFAULT_SERVER = "/private/tmp/core-agent-mlx-vlm/bin/mlx_vlm.server" | ||
| DEFAULT_APC_PATH = "/private/tmp/mlx-vlm-apc" | ||
| DEFAULT_LOG_DIR = "/private/tmp/core-agent-gemma4-stack" |
| return 0 | ||
|
|
||
| log_dir = Path(args.log_dir) | ||
| log_dir.mkdir(parents=True, exist_ok=True) |
Comment on lines
+229
to
+234
| process = subprocess.Popen( | ||
| lane_command(args.server, lane, args.host), | ||
| env=lane_env(lane, args.apc_path), | ||
| stdout=log_file, | ||
| stderr=subprocess.STDOUT, | ||
| ) |
Comment on lines
+221
to
+226
| process = subprocess.Popen( | ||
| lane_command(args.server, lane, args), | ||
| env=lane_env(lane, args), | ||
| stdout=log_file, | ||
| stderr=subprocess.STDOUT, | ||
| ) |
|
|
||
|
|
||
| def read_json(url: str, timeout: float = 2.0) -> dict | None: | ||
| request = urllib.request.Request(url) |
| deadline = time.monotonic() + timeout | ||
| while time.monotonic() < deadline: | ||
| try: | ||
| with urllib.request.urlopen(health_url(host, lane), timeout=2.0): |
|
|
||
|
|
||
| def read_json(url: str, timeout: float = 2.0) -> dict | None: | ||
| request = urllib.request.Request(url) |
| deadline = time.monotonic() + timeout | ||
| while time.monotonic() < deadline: | ||
| try: | ||
| with urllib.request.urlopen(health_url(host, lane), timeout=2.0): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


This pull request introduces several important configuration and documentation updates to the core-agent project, focusing on improving agent concurrency and rate limiting, updating plugin and MCP server integration, clarifying architecture and operational patterns, and adding new external dependencies. The changes also include a comprehensive implementation plan for aligning CLI and IPC handler behavior.
Configuration and Infrastructure Updates:
coreagent version in.claude-plugin/marketplace.jsonfrom0.14.0to0.18.0..mcp.jsonfrom a stdio-based server to an HTTP-based server, now requiring an authorization header..core/agents.yamlto resolve against~/Letheaninstead of$HOME/Code/.core, and clarified the comment.Agent Concurrency and Rate Limiting Enhancements:
opencodeagent in.core/agents.yaml, including per-model sub-limits and pacing settings. [1] [2]Dependency Management:
.gitmodules:external/api,external/cli,external/orm, andexternal/go-container, all tracking their respectivedevbranches.Documentation and Architecture Clarifications:
CLAUDE.mdandAGENTS.mdto reflect the current architecture, including new packages (pkg/runner,pkg/lemma,pkg/chathistory), expanded binary modes, and clarified plugin provider roles and personas/templates structure. [1] [2] [3] [4] [5] [6] [7]PLAN-cli-square-up.md, outlining the correct approach for CLI and IPC handler integration, anti-patterns to avoid, and the status of event handler implementations.