e39a16498c
feat: dual execution model (SSH CLI + HTTP pull)
...
- ExecutionMode enum: SshCli (orchestrator dispatches) | HttpPull (agent pulls)
- SSH CLI executor: spawn remote agents via ssh + CLI template
- Local subprocess as SSH special case (localhost)
- HostConfig with capability matching and load-based selection
- Dispatch loop: scan created tasks → select host → execute → update
- CliAdapterConfig: CLI templates for Codex and Claude Code
- Structured prompt construction (Issue → goal/constraints/validation)
- Output parsers: Codex JSON, Claude Code JSON, raw fallback
- TaskStatus::ReviewPending + review_count loop limit
- Forgejo webhook: pull_request (opened→review_pending, merged→completed)
- Forgejo webhook: push events (task/* branch → last_activity_at)
- HTTP API: dequeue only returns http_pull tasks
- HTTP API: status update only for http_pull mode
- Token auth config for http_pull agents
- Adapter module rewritten: AgentAdapter trait removed → config-driven CLI templates
- New fields: execution_mode, assigned_host, branch_name, pr_title, last_activity_at, review_count
- 30/30 tests pass
2026-05-12 14:07:56 +08:00
1bc7580ecc
refactor: remove Matrix bot, make agent-fleet platform-agnostic API service
...
- Remove src/integrations/matrix/ (bot connection, command parsing, notification formatting)
- Remove matrix-sdk dependency from Cargo.toml
- Remove MatrixConfig from config.rs and [matrix] from config.example.toml
- Add GET /api/v1/tasks (list with status/agent_id filter)
- Add POST /api/v1/tasks/{task_id}/retry (Failed/AgentLost → Assigned)
- Add EventStore::list_tasks() with parameterized query
- 29/29 tests pass
Platform integration (Telegram, Matrix, Feishu) is Agent-side responsibility.
agent-fleet is now a pure HTTP API orchestration engine.
2026-05-12 10:59:19 +08:00
6efca09018
feat: Matrix ChatOps bot (Task 5)
...
- Matrix bot via matrix-sdk: connect, join room, sync loop
- /fleet status: list all agents with status table
- /assign <agent> <issue>: manual task assignment
- /retry <issue>: re-queue failed/agent_lost task
- Notification formatting: task assigned/completed/failed, agent offline
- Per-agent thread support via Matrix Relation::Thread
- 15 tests: command parsing, notification formatting, fleet status table
2026-05-12 01:12:59 +08:00
f60f028f96
feat: Forgejo integration + Receipt protocol
...
Tasks completed:
- 4.1: Forgejo API client (reqwest, HMAC-SHA256, Issue/Comment/Label/PR)
- 4.2: POST /api/v1/webhooks/forgejo (signature verify, event parse)
- 4.3: Issue → Task conversion (agent:* → type, priority:* → priority)
- 4.4: Task status → Issue label sync (status:todo/doing/done)
- 4.5: Receipt → Issue comment (emoji + summary + artifacts)
- 4.6: Reconciliation stub
- 4.7: Tests for HMAC, Issue→Task conversion
- 6.1: POST /api/v1/receipts (validate + transition)
- 6.2: PR artifact validation via Forgejo API
- 6.3: No-trust check (only Completed after validation)
- 6.4: Receipt tests
19/19 tests pass. cargo check clean.
2026-05-11 19:42:03 +08:00
4e01728a67
feat: implement orchestrator core (Rust)
...
Task 1.1: ✅ Cargo.toml with axum, rusqlite, matrix-sdk, serde, etc.
Task 1.2: ✅ Directory structure: src/core, src/adapters, src/integrations, src/api
Task 1.5: ✅ config.example.toml with full schema
Task 2.1: ✅ Data models: Agent, Task, Receipt, Artifact, TaskEvent
Task 2.2: ✅ Event Store: SQLite append-only with task/agent tables
Task 2.3: ✅ Task state machine: created→assigned→running→completed/failed
Task 2.4: ✅ Global task queue with priority ordering
Task 2.5: ✅ Background timeout checker
Task 2.6: ✅ Retry policy with configurable max_retries
Compiles clean (warnings only, no errors).
API handler stubs in place for Phase 2.
2026-05-11 14:57:23 +08:00